完整错误
1
2
3
4
5
|
jsEnginScriptError:
Component is not found in path "components/comp/comp.js" (using by pages/index/index); onAppRoute
Error: Component is not found in path "components/comp/comp.js" (using by pages/index/index)
in e(...)
...
|
错误代码(json)
1
2
3
4
5
6
7
8
9
|
{
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "WeApp",
"navigationBarTextStyle": "black",
"usingComponents": {
"MyComp": "../../components/comp/comp.js"
}
}
|
解决
去掉.js
, 改为../../components/comp/comp
:
1
2
3
4
5
6
7
8
|
{
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTitleText": "WeApp",
"navigationBarTextStyle": "black",
"usingComponents": {
"MyComp": "../../components/comp/comp"
}
|