Skip to content

Commit

Permalink
Setup event route
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewiggins committed Dec 28, 2024
1 parent 183c5cb commit 3eb1f58
Show file tree
Hide file tree
Showing 21 changed files with 450 additions and 219 deletions.
40 changes: 0 additions & 40 deletions app/elements/events-list.mjs

This file was deleted.

11 changes: 0 additions & 11 deletions app/pages/events.mjs

This file was deleted.

91 changes: 0 additions & 91 deletions app/pages/events/$id.mjs

This file was deleted.

20 changes: 18 additions & 2 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
<link rel="stylesheet" href="/_public/styles/main.css" />
<link rel="shortcut icon" href="/_public/favicon.jpg" />
<link rel="stylesheet" href="https://use.typekit.net/smc6vzy.css" />
<link
<!-- <link
rel="stylesheet"
href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/styles/github-dark.min.css"
integrity="sha512-rO+olRTkcf304DQBxSWxln8JXCzTHlKnIdnMUwYvQa9/Jd4cQaNkItIUj6Z4nvW1dqK0SKXLbn9h4KwZTNtAyw=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
/>
/> -->
<!-- ${ sharing ? `
<meta
name="image"
Expand All @@ -40,5 +40,21 @@
<body>
<div id="root"></div>
<script src="./src/index.tsx" type="module"></script>
<script
src="https://kit.fontawesome.com/95fd764ad0.js"
crossorigin="anonymous"
async
></script>
<!-- <script
src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/11.8.0/highlight.min.js"
integrity="sha512-rdhY3cbXURo13l/WU9VlaRyaIYeJ/KBakckXIvJNAQde8DgpOmE+eZf7ha4vdqVjTtwQt69bD2wH2LXob/LB7Q=="
crossorigin="anonymous"
referrerpolicy="no-referrer"
></script>
<script>
hljs.highlightAll()
</script> -->
<!--script src="https://unpkg.com/@mux/mux-player"></script-->
<!--script src="/_public/scripts/app.js"></script-->
</body>
</html>
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
},
"scripts": {
"build": "vite build",
"serve": "vite preview",
"serve": "vite preview --port 3333",
"start": "vite",
"lint": "npm run tsc && npm run check-format",
"eslint": "eslint src/**/*.{js,jsx,ts,tsx}",
Expand Down
11 changes: 10 additions & 1 deletion src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,12 @@ import welcomePath from './routes/welcome.md'

import { createMarkdownRoute } from './utils/createMarkdownRoute'

const routes = [
interface Route {
url: string
component: preact.AnyComponent<any>
}

const routes: Route[] = [
{
url: '/about-us',
component: lazy(() => createMarkdownRoute(aboutUsPath)),
Expand All @@ -37,6 +42,10 @@ const routes = [
url: '/code-of-conduct',
component: lazy(() => createMarkdownRoute(codeOfConductPath)),
},
{
url: '/events/:id?',
component: lazy(() => import('./routes/events')),
},
{
url: '/join',
component: lazy(() => createMarkdownRoute(joinPath)),
Expand Down
Loading

0 comments on commit 3eb1f58

Please sign in to comment.