Skip to content

Commit 951822c

Browse files
committed
fix: docs and code routing warnings
1 parent 41c74aa commit 951822c

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/pages/package-code/[...path].vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,8 @@ import { formatBytes } from '~/utils/formatters'
88
99
definePageMeta({
1010
name: 'code',
11-
// Both alias paths need to be (.+) so that they don't match the package page alias.
12-
alias: ['/package/code/:path(.+)', '/code/:path(.+)'],
11+
path: '/package-code/:path+',
12+
alias: ['/package/code/:path+', '/code/:path+'],
1313
})
1414
1515
const route = useRoute('code')

app/pages/package-docs/[...path].vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import { assertValidPackageName, fetchLatestVersion } from '#shared/utils/npm'
55
66
definePageMeta({
77
name: 'docs',
8-
// Both alias paths need to be (.+) so that they don't match the package page alias.
9-
alias: ['/package/docs/:path(.+)', '/docs/:path(.+)'],
8+
path: '/package-docs/:path+',
9+
alias: ['/package/docs/:path+', '/docs/:path+'],
1010
})
1111
1212
const route = useRoute('docs')

0 commit comments

Comments
 (0)