Skip to content

Commit 1c41ec6

Browse files
committed
perf(docs): 🔍 Seo improvements
1 parent 69bd0ad commit 1c41ec6

File tree

4 files changed

+37
-41
lines changed

4 files changed

+37
-41
lines changed

docs/app/pages/index.vue

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -80,18 +80,18 @@ const unlocked = ref(false)
8080
<ClientOnly>
8181
<div class="[perspective:600px] mb-32 group">
8282
<div ref="target" class="h-48 max-w-64 mx-auto" :style="cardStyle">
83-
<img loading="lazy" alt="browser" :class="unlocked ? 'opacity-100' : 'opacity-40'" class="absolute left-0 top-0 h-full w-full" src="~/assets/browser.svg" :style="browserStyle">
84-
<img loading="lazy" alt="lock-sign" :class="unlocked ? 'opacity-0' : 'opacity-100'" class="absolute left-0 h-32 top-8 w-full" src="~/assets/nuxt-oidc-auth.svg" :style="logoStyle">
85-
<button name="nuxt-oidc-auth-unlock" class="absolute w-full h-full" @click="unlocked = !unlocked" />
83+
<img alt="browser" :class="unlocked ? 'opacity-100' : 'opacity-40'" class="absolute left-0 top-0 h-full w-full" src="~/assets/browser.svg" :style="browserStyle">
84+
<img alt="lock-sign" :class="unlocked ? 'opacity-0' : 'opacity-100'" class="absolute left-0 h-32 top-8 w-full" src="~/assets/nuxt-oidc-auth.svg" :style="logoStyle">
85+
<button name="Browser unlock visual" aria-label="Browser unlock visual" class="absolute w-full h-full" @click="unlocked = !unlocked" />
8686
</div>
8787
<div class="transition-all duration-300 ease-out h-2 absolute group-hover:shadow-[0px_70px_32px_4px_rgba(0,220,130,0.75)] shadow-[0px_70px_33px_3px_rgba(0,220,130,0.75)] bottom-0 lg:left-[27.5%] left-[35%] w-[30%] lg:w-[45%] bg-slate-700" :style="shadowStyle" />
8888
</div>
8989
<template #fallback>
9090
<div class="[perspective:600px] mb-32 group">
9191
<div ref="target" class="h-48 max-w-64 mx-auto">
92-
<img loading="lazy" alt="browser" :class="unlocked ? 'opacity-100' : 'opacity-40'" class="absolute left-0 top-0 h-full w-full" src="~/assets/browser.svg">
93-
<img loading="lazy" alt="lock-sign" :class="unlocked ? 'opacity-0' : 'opacity-100'" class="absolute left-0 h-32 top-8 w-full" src="~/assets/nuxt-oidc-auth.svg">
94-
<button class="absolute w-full h-full" @click="unlocked = !unlocked" />
92+
<img alt="browser" :class="unlocked ? 'opacity-100' : 'opacity-40'" class="absolute left-0 top-0 h-full w-full" src="~/assets/browser.svg">
93+
<img alt="lock-sign" :class="unlocked ? 'opacity-0' : 'opacity-100'" class="absolute left-0 h-32 top-8 w-full" src="~/assets/nuxt-oidc-auth.svg">
94+
<button name="Browser unlock visual" aria-label="Browser unlock visual" class="absolute w-full h-full" @click="unlocked = !unlocked" />
9595
</div>
9696
</div>
9797
</template>

docs/nuxt.config.ts

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,9 @@ export default defineNuxtConfig({
1313
'@nuxt/ui',
1414
'@nuxtjs/seo',
1515
'@nuxt/image',
16-
'nuxt-delay-hydration',
16+
'nuxt-vitalizer',
1717
],
1818

19-
delayHydration: {
20-
mode: 'init',
21-
},
22-
2319
future: {
2420
compatibilityVersion: 4,
2521
},
@@ -66,6 +62,9 @@ export default defineNuxtConfig({
6662
},
6763

6864
fonts: {
65+
families: [
66+
{ name: 'DM Sans', provider: 'bunny', weights: [400, 700] },
67+
],
6968
providers: {
7069
google: false,
7170
},

docs/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,15 @@
2424
"@nuxtjs/seo": "^2.0.0-rc.23",
2525
"@vueuse/core": "^11.1.0",
2626
"@vueuse/nuxt": "^11.1.0",
27-
"nuxt": "^3.13.2"
27+
"nuxt": "^3.13.2",
28+
"nuxt-vitalizer": "^0.10.0"
2829
},
2930
"devDependencies": {
3031
"@antfu/eslint-config": "^3.8.0",
3132
"@azure/static-web-apps-cli": "^2.0.1",
3233
"@nuxt/eslint": "^0.6.0",
3334
"dotenv-cli": "^7.4.2",
3435
"eslint": "^9.13.0",
35-
"nuxt-delay-hydration": "^1.3.8",
3636
"typescript": "^5.6.3",
3737
"vue-tsc": "^2.1.6"
3838
}

pnpm-lock.yaml

Lines changed: 25 additions & 28 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)