当我运行离子服务时出现此错误Ionic CLI将退出.请检查上面的任何输出以获取错误详情.
我的离子信息
$ionic info
Ionic:
ionic (Ionic CLI) : 4.0.1 (C:\Users\Pc\AppData\Roaming\npm\node_modules\ionic)
Ionic Framework : ionic-angular 3.9.2
@ionic/app-scripts : 3.1.8
Cordova:
cordova (Cordova CLI) : 8.0.0
Cordova Platforms : android 7.0.0
System:
Android SDK Tools : 25.3.1
NodeJS : v6.10.1 (C:\Program Files\nodejs\node.exe)
npm : 5.3.0
OS : Windows 10
Environment:
ANDROID_HOME : C:\Users\Pc\AppData\Local\Android\sdk
Run Code Online (Sandbox Code Playgroud) 我有一个有角度的项目,我想在移动设备上使用 ionic。我做到了ionic init。
当我运行命令时ionic serve,我收到此错误:
> ng.cmd run app:serve --host=localhost --port=8100
[ng] Error: Unknown arguments: host, port
[ERROR] ng has unexpectedly closed (exit code 1).
The Ionic CLI will exit. Please check any output above for error details.
Run Code Online (Sandbox Code Playgroud)
这是我的package.json:
> ng.cmd run app:serve --host=localhost --port=8100
[ng] Error: Unknown arguments: host, port
[ERROR] ng has unexpectedly closed (exit code 1).
The Ionic CLI will exit. Please check any output above for error details.
Run Code Online (Sandbox Code Playgroud)
如何修复主机/端口缺少参数?