Skip to content

Commit c3ec2d3

Browse files
committed
✨ chore: remove prismjs
1 parent ada510e commit c3ec2d3

File tree

6 files changed

+60
-691
lines changed

6 files changed

+60
-691
lines changed

bun.lockb

-16 Bytes
Binary file not shown.

components/midori/e2e-type-safety.vue

Lines changed: 9 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,3 @@
1-
<script setup lang="ts">
2-
import Prism from 'vue-prism-component'
3-
4-
const server = `// server.ts
5-
import { Elysia, t } from 'elysia'
6-
7-
const app = new Elysia()
8-
.patch(
9-
'/user/age',
10-
({ body }) => signIn(body),
11-
{
12-
body: t.Object({
13-
name: t.String(),
14-
age: t.Number()
15-
})
16-
}
17-
)
18-
.listen(80)
19-
20-
export type App = typeof app`
21-
22-
const client = `// client.ts
23-
import { edenTreaty } from '@elysiajs/eden'
24-
import type { App } from 'server'
25-
26-
const eden = edenTreaty<App>('http://localhost')
27-
28-
await eden.user.age.patch({
29-
name: 'saltyaom',
30-
age: '21'
31-
})`
32-
</script>
33-
341
<template>
352
<section class="flex flex-col justify-center items-center w-full max-w-6xl mx-auto py-4">
363
<!-- <h3 class="text-2xl mr-auto md:mx-auto font-medium text-gray-400">
@@ -54,25 +21,20 @@ await eden.user.age.patch({
5421

5522
<section class="flex flex-col lg:flex-row gap-8 w-full max-w-5xl my-8">
5623
<div class="w-full !text-base !font-mono rounded-xl">
57-
<slot name="server">test</slot>
24+
<slot name="server"></slot>
5825
</div>
5926
<div class="relative w-full !text-base !font-mono rounded-xl">
6027
<slot name="client"></slot>
61-
<!-- <div
62-
class="absolute p-1 rounded bg-red-400/25"
63-
style="
64-
top: 13.5em;
65-
left: 6.375em;
66-
width: 2.5em;
28+
<div class="absolute p-1 rounded bg-red-400/25" style="
29+
top: 13.2em;
30+
left: 5.9em;
31+
width: 2.2em;
6732
height: 1.375em;
68-
"
69-
/>
70-
<p
71-
class="absolute px-3 py-1.5 rounded bg-white dark:bg-gray-700 border dark:border-gray-600"
72-
style="top: 15.25em; left: 3.25em"
73-
>
33+
" />
34+
<p class="absolute px-3 py-1.5 rounded bg-white dark:bg-gray-700 border dark:border-gray-600"
35+
style="top: 15.25em; left: 3.25em">
7436
Type 'string' is not assignable to type 'number'
75-
</p> -->
37+
</p>
7638
</div>
7739
</section>
7840
</section>

components/midori/index.vue

Lines changed: 8 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@ import Community from './community.vue'
1313
import QuickStart from './quickstart.vue'
1414
import Sponsor from './sponsor.vue'
1515
16-
import 'prismjs'
17-
import 'prismjs/components/prism-typescript'
1816
1917
import '../tailwind.css'
2018
import './midori.css'
@@ -30,19 +28,6 @@ const isDark = useDark()
3028
<link rel="preconnect" href="https://fonts.googleapis.com" />
3129
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin="true" />
3230

33-
<link v-if="isDark" rel="preload"
34-
href="https://cdn.jsdelivr.net/gh/katorlys/prism-theme-github/themes/prism-theme-github-light.css" priority="high"
35-
as="style" />
36-
<link v-else rel="preload"
37-
href="https://cdn.jsdelivr.net/gh/katorlys/prism-theme-github/themes/prism-theme-github-dark.css" priority="high"
38-
as="style" />
39-
40-
<link v-if="isDark" rel="stylesheet"
41-
href="https://cdn.jsdelivr.net/gh/katorlys/prism-theme-github/themes/prism-theme-github-dark.css" type="text/css" />
42-
<link v-else rel="stylesheet"
43-
href="https://cdn.jsdelivr.net/gh/katorlys/prism-theme-github/themes/prism-theme-github-light.css"
44-
type="text/css" />
45-
4631
<div id="landing" class="dark:bg-gray-900/60">
4732
<Hero />
4833
<article class="flex flex-col gap-4 px-6">
@@ -68,7 +53,14 @@ const isDark = useDark()
6853
</template>
6954
</E2ETypeSafety>
7055
<Plugins />
71-
<Editor />
56+
<Suspense>
57+
<Editor />
58+
<template #fallback>
59+
<video muted autoplay loop>
60+
<source src="/assets/elysia.mp4" />
61+
</video>
62+
</template>
63+
</Suspense>
7264
<Community />
7365
<Sponsor />
7466
<hr class="border-gray-200 dark:border-gray-600" />

0 commit comments

Comments
 (0)