mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
fix(nuxt): don't incl overridden layer pages as nested children (#23238)
This commit is contained in:
parent
bc8a1fa614
commit
137c0b6054
@ -52,7 +52,7 @@ export async function resolvePagesRoutes (): Promise<NuxtPage[]> {
|
|||||||
}
|
}
|
||||||
scannedFiles.sort((a, b) => a.relativePath.localeCompare(b.relativePath))
|
scannedFiles.sort((a, b) => a.relativePath.localeCompare(b.relativePath))
|
||||||
|
|
||||||
const allRoutes = await generateRoutesFromFiles(scannedFiles, nuxt.options.experimental.typedPages, nuxt.vfs)
|
const allRoutes = await generateRoutesFromFiles(uniqueBy(scannedFiles, 'relativePath'), nuxt.options.experimental.typedPages, nuxt.vfs)
|
||||||
|
|
||||||
return uniqueBy(allRoutes, 'path')
|
return uniqueBy(allRoutes, 'path')
|
||||||
}
|
}
|
||||||
|
5
test/fixtures/basic/extends/node_modules/foo/pages/override.vue
generated
vendored
5
test/fixtures/basic/extends/node_modules/foo/pages/override.vue
generated
vendored
@ -1,3 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>This page should be overriden by bar</div>
|
<div>This page should be overriden by bar</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import invalidImport from '234897f'
|
||||||
|
console.log(invalidImport)
|
||||||
|
</script>
|
||||||
|
Loading…
Reference in New Issue
Block a user