Skip to content

Commit d2e2d38

Browse files
authored
docs: meta title on api pages (#21447)
1 parent fa4835e commit d2e2d38

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

packages/docs/src/App.vue

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,16 @@
2121
const path = computed(() => route.path.replace(`/${locale.value}/`, ''))
2222
2323
const meta = computed(() => {
24+
let title = route.meta.title
25+
26+
// API pages
27+
if (route.meta.title === 'API') {
28+
const name = route.params.name as string
29+
title = `${name.charAt(0).toUpperCase()}${camelize(name.slice(1))} API`
30+
}
31+
2432
return genAppMetaInfo({
25-
title: `${route.meta.title}${path.value === '' ? '' : ' — Vuetify'}`,
33+
title: `${title}${path.value === '' ? '' : ' — Vuetify'}`,
2634
description: frontmatter.value?.meta.description,
2735
keywords: frontmatter.value?.meta.keywords,
2836
assets: frontmatter.value?.assets,

0 commit comments

Comments
 (0)