My Ionic info:
cli packages: (/usr/lib/node_modules)
@ionic/cli-utils : 1.9.2
ionic (Ionic CLI) : 3.9.2
global packages:
Cordova CLI : 7.0.1
local pack
Please use these commands in your project.
sudo sysctl fs.inotify.max_user_watches=524288
sudo sysctl -p --system
And again run ionic serve
Install ws:
npm install ws@3.3.2 --save-dev --save-exact
Try npm run ionic:serve. Similar issue occurred when installing the latest cordova update.
In ionic 3 you have to type:
cordova run android or cordova run ios, to deploy your build in
device.
cordova build android or cordova build ios, for build only.
My answers works. My machine is also having a different package of Node which I forgot about in the first place.
So I've removed node_modules using:
sudo rm -rf /opt/local/bin/node /opt/local/include/node /opt/local/lib/node_modules
sudo rm -rf /usr/local/bin/npm /usr/local/share/man/man1/node.1 /usr/local/lib/dtrace/node.
To make things less complicated with all cli - head up back https://nodejs.org/ and install back the LTS package
Uninstall Node from brew
re-install node.js using conventional way using the installer
Use these commands in your prompt.
npm cache clear --force
rm -rf node_modules/
npm install -d