mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
fix(nuxi): respect custom pages directory (#2813)
This commit is contained in:
parent
1ca9424910
commit
7f62ed1e32
@ -78,7 +78,7 @@ export default defineNuxtCommand({
|
|||||||
|
|
||||||
const isDirChange = ['addDir', 'unlinkDir'].includes(event)
|
const isDirChange = ['addDir', 'unlinkDir'].includes(event)
|
||||||
const isFileChange = ['add', 'unlink'].includes(event)
|
const isFileChange = ['add', 'unlink'].includes(event)
|
||||||
const reloadDirs = ['pages', 'components', 'composables']
|
const reloadDirs = [currentNuxt.options.dir.pages, 'components', 'composables']
|
||||||
|
|
||||||
if (isDirChange) {
|
if (isDirChange) {
|
||||||
const dir = reloadDirs.find(dir => file.endsWith(dir))
|
const dir = reloadDirs.find(dir => file.endsWith(dir))
|
||||||
|
Loading…
Reference in New Issue
Block a user