babel 'command not recognized' after installation

Multi tool use


babel 'command not recognized' after installation
I decided to install babel-preset-env
after realising that babel-preset-es2015
had been depricated. Source
However that resulted in the following error:
babel-preset-env
babel-preset-es2015
Error code:
enter image description here
At this point I realized that babel
too was not recognized as an internal or external command
. So I tried babel by typing: npm install babel-cli --save-dev
, which sadly did not change anything, the error persisted.
babel
recognized as an internal or external command
npm install babel-cli --save-dev
Error code: enter image description here
Other similiar questions/answers are old e.g. this one for that reason I hoped someone could give me an updated answer.
The overall issue: Why are the commands not recognized even after installation?
1 Answer
1
More than likely because you have not added the .node_modules.bin
directory to your path.
.node_modules.bin
Until you do that, you can use .node_modules.binbabel
.node_modules.binbabel
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.