I had this error after upgrading my IDE:
'ng' is not recognized as an internal or external command, operable program or batch file.
Run in your command line:
npm install -g @angular/cli
Buy me a drink 🍺 to keep me motivated to create free content like this!