-bash: cordova: command not found on mac after installation of cordova

After installation of cordova you might face the issue:-bash: cordova: command not found 

To install cordova on your mac you need to install node and npm first. After installation of this you can install cordova. 

To install cordova run the following commands in your terminal:

npm install -g cordova

 After successfull installetion of cordova you will get the output like this:

/usr/local/Cellar/node/13.2.0/bin/cordova -> /usr/local/Cellar/node/13.2.0/lib/node_modules/cordova/bin/cordova

+ cordova@10.0.0

updated 1 package in 127.643s

Now copy the highlighted path and make a siblink into your local installetion directory.

sudo ln -s /usr/local/Cellar/node/13.2.0/bin/cordova /usr/local/bin

Now cordova will be available for use by cordova command.

Enjoy it.



Keywords: