更新
This commit is contained in:
@@ -49,7 +49,11 @@ function loadComponent(componentPath) {
|
||||
}
|
||||
|
||||
// 如果是简单的组件名称,从 pages 目录加载
|
||||
return modules[`../pages/${componentPath}/index.vue`]
|
||||
if (componentPath.endsWith('index')){
|
||||
return modules[`../pages/${componentPath}.vue`]
|
||||
} else {
|
||||
return modules[`../pages/${componentPath}/index.vue`]
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user