deno.land / x / opine@2.3.4 / examples / react / components / App.tsx

نووسراو ببینە
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import React from "https://esm.sh/react@17.0.2?dev";import { Title } from "./Title.tsx";import { List } from "./List.tsx";
export const App = ({ isServer = false }) => { if (isServer) { return ( <> <Title /> <p className="app_loading">Loading Doggos...</p> </> ); }
return ( <> <Title /> <React.Suspense fallback={<p className="app_loading">Loading Doggos...</p>} > <List /> </React.Suspense> </> );};
opine

Version Info

Tagged at
2 years ago