From f7271130ceebe1fd2d184298fc2d1e892ab7d64f Mon Sep 17 00:00:00 2001 From: Jan Tuomi Date: Sat, 5 Feb 2022 23:17:25 +0200 Subject: More things --- src/App.tsx | 22 ---------------------- 1 file changed, 22 deletions(-) (limited to 'src/App.tsx') diff --git a/src/App.tsx b/src/App.tsx index 905149e..9e78af3 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,28 +1,9 @@ -import { useExamples } from "./api" import styles from "./App.module.css" import Editor from "./Editor" import Tutorial from "./Tutorial" import icon from "./favicon.png" const App = () => { - const examples = useExamples() - - const renderExamples = () => { - switch (examples.type) { - case "not_yet_requested": - case "loading": - return
Loading examples...
- case "failed": - return
- An unexpected error occurred while loading examples. See console for details. -
- case "success": - return examples.data.map((example) => -
{example.title}
, - ) - } - } - return (
@@ -34,9 +15,6 @@ const App = () => { A Mere Stack Language
-
- {renderExamples()} -
-- cgit v1.3