[英]Nativescript + Vue: sync only works the first time on both device and emulator
Project Nativescript + Vue Project Nativescript + Vue
NativeScript CLI version: 5.4.2 NativeScript CLI版本:5.4.2
package.json 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"
},
When I build and run "tns run" or "tns debug" or use "Run on device" on Sidekick, the syncronization on both device and emulator only works the first time. 当我在Sidekick上构建并运行“ tns run”或“ tns debug”或使用“在设备上运行”时,设备和仿真器上的同步仅在第一次工作。 From the second time I get blank screen or get the error:
从第二次起,我出现黑屏或出现错误:
Calling js method onCreateView failed
调用js方法onCreateView失败
Error: View already has a parent.
错误:视图已经有一个父级。 View: Page(23) Parent: TabViewItem(22)
视图:页面(23)父级:TabViewItem(22)
I've already tried to disable Hot Module Replacement but the problem continue. 我已经尝试禁用热模块更换,但是问题仍然存在。 The only solution is to uninstall the app and rerun the local build.
唯一的解决方案是卸载应用程序并重新运行本地版本。
The problem occours on both local and cloud build. 该问题同时发生在本地和云构建上。
Any idea? 任何想法? Thanks
谢谢
实际上,我使用NS6重构了我的应用程序,现在它运行良好!
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.