You can install the latest version of Ionic and Cordova CLI using a single command
$ npm install ionic cordova -g
Still, you may get a notification message saying
"Please install your Cordova CLI to version >=4.2.0 `npm install -g cordova`"
Or, incorrect version numbers for ionic and cordova even after installing their latest versions globally.
(more…)