问题描述
我使用此命令创建了项目 vue init nativescript-vue/vue-cli-template <project name>
这是我用来调试的命令 ns debug ios/android
这曾经在以前的版本中开箱即用
经过研究,我发现这个 domainDebugger.getNetwork()
返回 undefined(不知道是不是原因,如果是如何解决)。
它位于:node_modules/@nativescript/core/http/http-request/index.ios.js
添加当前包 JSON
"dependencies": {
"vuex": "^3.5.1","@vue/devtools": "^5.3.3","nativescript-socketio": "^3.3.1","nativescript-vue-devtools": "^1.4.0","nativescript-toasty": "^3.0.0-alpha.2","@nativescript/theme": "^2.3.3","nativescript-vue": "^2.8.1","@nativescript/core": "^7.0.3"
},"devDependencies": {
"@babel/core": "^7.11.6","@babel/preset-env": "^7.11.5","@nativescript/ios": "7.0.6","@nativescript/webpack": "^3.0.4","babel-loader": "^8.1.0","nativescript-vue-template-compiler": "^2.8.1","nativescript-worker-loader": "~0.12.1","sass": "^1.26.10","vue-loader": "^15.9.3"
}
解决方法
此问题目前正在处理中,已部分修复 https://github.com/NativeScript/NativeScript/issues/8966 https://github.com/NativeScript/NativeScript/issues/9058
,您的问题可能与此tweet有关。
必须更新依赖项并清理。
npm i @nativescript/ios
npm i @nativescript/core
ns clean