问题描述:
用npm run build生成代码后,刷新开发者工具或者随便访问一两页就会出现以下提示:
TypeError: Cannot read property '$pages' of undefined
at Object.$createPage (http://127.0.0.1:60171/appservice/npm/wepy/lib/base.js:1:2877)
at http://127.0.0.1:60171/appservice/pages/index.js:1:3683
at require (http://127.0.0.1:60171/appservice/__dev__/WAService.js:1:880954)
at <anonymous>:6:7
at HTMLScriptElement.scriptLoaded (http://127.0.0.1:60171/appservice/appservice?t=1551670670030:1427:21)
at HTMLScriptElement.script.onload (http://127.0.0.1:60171/appservice/appservice?t=1551670670030:1439:20)
后来发现app.js和app.wxss文件变空白了。反复试过好多次,偶尔只会把app.wxss清空。而且不用开发者工具访问就没事。重启也无果。
Environment
- Platform: 开发者工具
- Platform version: 1.02.1902010
- wepy-cli version: 1.7.2 or 1.7.3
- wepy version: 1.7.2
- 调试基础库:2.5.1
1条答案
按热度按时间5tmbdcev1#
我开发过程经常出现这种情况: