Nativescript + Vue:同步仅在设备和模拟器上第一次有效
Nativescript + Vue: sync only works the first time on both device and emulator
Nativescript + Vue 项目
NativeScript CLI 版本:5.4.2
package.json
"dependencies": {
"axios": "0.19.0",
"jwt-decode": "2.2.0",
"moment": "^2.24.0",
"nativescript-iqkeyboardmanager": "^1.5.1",
"nativescript-pulltorefresh": "2.3.0",
"nativescript-theme-core": "~1.0.6",
"nativescript-ui-listview": "6.4.2",
"nativescript-vue": "~2.2.2",
"nativescript-vue-navigator": "0.0.3",
"tns-core-modules": "~5.4.3",
"vuex": "3.1.1"
},
"devDependencies": {
"@babel/core": "~7.4.5",
"@babel/preset-env": "~7.4.5",
"babel-loader": "~8.0.6",
"nativescript-dev-webpack": "^0.24.1",
"nativescript-vue-template-compiler": "~2.2.2",
"node-sass": "^4.12.0",
"vue-loader": "^15.7.1"
},
当我在 Sidekick 上构建和 运行 "tns run" 或 "tns debug" 或使用 "Run on device" 时,设备和模拟器上的同步仅在第一次工作。
从第二次我得到黑屏或得到错误:
Calling js method onCreateView failed
Error: View already has a parent. View: Page(23) Parent:
TabViewItem(22)
我已经尝试禁用热模块更换,但问题仍然存在。
唯一的解决办法是卸载应用程序并重新运行本地构建。
本地和云端构建都会出现这个问题。
有什么想法吗?
谢谢
实际上我用 NS6 重构了我的应用程序,现在它运行良好!
Nativescript + Vue 项目
NativeScript CLI 版本:5.4.2
package.json
"dependencies": {
"axios": "0.19.0",
"jwt-decode": "2.2.0",
"moment": "^2.24.0",
"nativescript-iqkeyboardmanager": "^1.5.1",
"nativescript-pulltorefresh": "2.3.0",
"nativescript-theme-core": "~1.0.6",
"nativescript-ui-listview": "6.4.2",
"nativescript-vue": "~2.2.2",
"nativescript-vue-navigator": "0.0.3",
"tns-core-modules": "~5.4.3",
"vuex": "3.1.1"
},
"devDependencies": {
"@babel/core": "~7.4.5",
"@babel/preset-env": "~7.4.5",
"babel-loader": "~8.0.6",
"nativescript-dev-webpack": "^0.24.1",
"nativescript-vue-template-compiler": "~2.2.2",
"node-sass": "^4.12.0",
"vue-loader": "^15.7.1"
},
当我在 Sidekick 上构建和 运行 "tns run" 或 "tns debug" 或使用 "Run on device" 时,设备和模拟器上的同步仅在第一次工作。 从第二次我得到黑屏或得到错误:
Calling js method onCreateView failed
Error: View already has a parent. View: Page(23) Parent: TabViewItem(22)
我已经尝试禁用热模块更换,但问题仍然存在。 唯一的解决办法是卸载应用程序并重新运行本地构建。
本地和云端构建都会出现这个问题。
有什么想法吗? 谢谢
实际上我用 NS6 重构了我的应用程序,现在它运行良好!