更新node.js后,我发现了这个问题..当我运行 ionic cordova run android --livereload 时,它在本地主机中运行
我该如何解决这个问题?请帮我..
离子信息:
Ionic CLI : 5.2.1
Ionic Framework : @ionic/angular 4.6.0
@angular-devkit/build-angular : 0.13.9
@angular-devkit/schematics : 7.3.9
@angular/cli : 7.3.9
@ionic/angular-toolkit : 1.5.1
Cordova:
Cordova CLI : 9.0.0 ([email protected] /cdn-cgi/l/email-protection)
Cordova Platforms : android 8.0.0
Cordova Plugins : cordova-plugin-ionic-keyboard 2.1.3, cordova-plugin-ionic-webview 4.1.1, (and 4 other plugins)
Utility:
cordova-res : not installed
native-run : 0.2.7
System:
NodeJS : v10.16.0 (C:\Program Files\nodejs\node.exe)
npm : 6.9.2
OS : Windows 10
所以这是 Ionic-cli v5.2.1 的新变化
你可以使用这个命令
离子服务--地址=0.0.0.0
或者在你的情况下
ionic cordova 运行 android --livereload --address=0.0.0.0
或者如果您有特定的网址
ionic cordova 运行 android --livereload-url=http://本地主机:8100 http://localhost:8100
这将像以前一样在本地主机和外部 URL 上启动服务器。
请参阅此更新文档以获取更多信息https://ionicframework.com/docs/cli/commands/cordova-run https://ionicframework.com/docs/cli/commands/cordova-run
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)