本帖最后由 vivo官方技术团队 于 2019-7-29 09:38 编辑
Q:Module not found: Error: Can't resolve 'babel-runtime/regenerator' in '/quickapp-project/src/common' A:该问题是hap-toolkit从0.1.1以下版本更新到最新后babel库更新了导致的。使用新的引入方式可以修复, require('babel-runtime/regenerator') 修改为 require('@babel/runtime/regenerator')
Q:[ERRO] Module build failed (from /quickapp-project/node_modules/babel-loader/lib/index.js) A:在终端通过npm手动安装babel-loader库即可,npm i -D babel-loader
Q: 更新1.5.0之后报错, Module not found: Error: Can't resolve 'base64-js' in '/Applications/快应用开发工具.app/Contents/Resources/app/extensions/hap-debugger' Module not found: Error: Can't resolve 'ieee754' in '/Applications/快应用开发工具.app/Contents/Resources/app/extensions/hap-debugger' Module not found: Error: Can't resolve isarray' in '/Applications/快应用开发工具.app/Contents/Resources/app/extensions/hap-debugger'
A:按下面步骤修复。
1、cd /Applications/快应用开发工具.app/Contents/Resources/app/extensions/hap-debugger
2、sudo mv node_modules node_modules_bak
3、sudo npm i base64-js
4、sudo npm i ieee754
5、sudo npm i isarray
6、sudo mv -f node_modules_bak/aaptjs node_modules_bak/terser node_modules_bak/adb-driver node_modules
7、重启开发工具
|