mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
fix(nuxt): fall back to original component filePath
(#28925)
This commit is contained in:
parent
cdc4a23107
commit
cea69b6832
@ -171,7 +171,7 @@ export default defineNuxtModule<ComponentsOptions>({
|
|||||||
for (const component of newComponents) {
|
for (const component of newComponents) {
|
||||||
if (!(component as any /* untyped internal property */)._scanned && !(component.filePath in nuxt.vfs) && !existsSync(component.filePath)) {
|
if (!(component as any /* untyped internal property */)._scanned && !(component.filePath in nuxt.vfs) && !existsSync(component.filePath)) {
|
||||||
// attempt to resolve component path
|
// attempt to resolve component path
|
||||||
component.filePath = await resolvePath(component.filePath)
|
component.filePath = await resolvePath(component.filePath, { fallbackToOriginal: true })
|
||||||
}
|
}
|
||||||
if (component.mode === 'client' && !newComponents.some(c => c.pascalName === component.pascalName && c.mode === 'server')) {
|
if (component.mode === 'client' && !newComponents.some(c => c.pascalName === component.pascalName && c.mode === 'server')) {
|
||||||
newComponents.push({
|
newComponents.push({
|
||||||
|
Loading…
Reference in New Issue
Block a user