aboutsummaryrefslogtreecommitdiff
path: root/packages/anastasis-webui/src/components/app.tsx
diff options
context:
space:
mode:
authorFlorian Dold <florian@dold.me>2021-10-11 10:58:55 +0200
committerFlorian Dold <florian@dold.me>2021-10-11 10:58:55 +0200
commitf23a8ee4d356645ae3f91862552b256f230c6bcb (patch)
tree641bf808ef6c6bf7eb003d96f6f7ed5654f854b8 /packages/anastasis-webui/src/components/app.tsx
parent0bbaafcd36ce68f95faee0b91738a169848c7a90 (diff)
downloadwallet-core-f23a8ee4d356645ae3f91862552b256f230c6bcb.tar.gz
wallet-core-f23a8ee4d356645ae3f91862552b256f230c6bcb.tar.bz2
wallet-core-f23a8ee4d356645ae3f91862552b256f230c6bcb.zip
anastasis-webui: first commit
Diffstat (limited to 'packages/anastasis-webui/src/components/app.tsx')
-rw-r--r--packages/anastasis-webui/src/components/app.tsx23
1 files changed, 23 insertions, 0 deletions
diff --git a/packages/anastasis-webui/src/components/app.tsx b/packages/anastasis-webui/src/components/app.tsx
new file mode 100644
index 000000000..5abb12a3d
--- /dev/null
+++ b/packages/anastasis-webui/src/components/app.tsx
@@ -0,0 +1,23 @@
+import { FunctionalComponent, h } from 'preact';
+import { Route, Router } from 'preact-router';
+
+import Home from '../routes/home';
+import Profile from '../routes/profile';
+import NotFoundPage from '../routes/notfound';
+import Header from './header';
+
+const App: FunctionalComponent = () => {
+ return (
+ <div id="preact_root">
+ <Header />
+ <Router>
+ <Route path="/" component={Home} />
+ <Route path="/profile/" component={Profile} user="me" />
+ <Route path="/profile/:user" component={Profile} />
+ <NotFoundPage default />
+ </Router>
+ </div>
+ );
+};
+
+export default App;