Angular - Do you know the stuff to install?
5/07/2018 3:23 AM by
It is suggested using cli.angular.io to start an Angular project, especially when learning as it is the easiest way to both get started and also follow best practices.
- Check that you are running at node 8.11+ (note: some still use 6.9+ as it works with Angular CLI). Check that you are running npm 5+ by running node in a terminal/console window.
Older versions produce errors, but newer versions are fine. If you have older versions please install the latest version from here https://nodejs.org/en
Check you have the right versions:
- Install git https://git-scm.com Check you have git:
- Check you have the latest version of the Angular cli by running the below ng -v command in the terminal and checking the latest version on GitHub here https://github.com/angular/angular-cli
- Figure: Current version to check on GitHub
If you are not running the latest version we recommend you run the below commands to update the cli.
npm uninstall -g @angular/ cli (not needed to run anymore as it is done automatically)
npm install -g @angular/ cli
- Getting errors?
If you get node gyp errors, follow instructions here https://github.com/nodejs/node-gyp
If you get permission errors, follow instructions here https://docs.npmjs.com/getting-started/fixing-npm-permissions
- If you are new to Angular we recommend you use VSCode - http://code.visualstudio.com - versus Visual Studio 2015/17 as the TypeScript support and project directory (without a Visual Studio Project) is easier.
Do you feel this rule needs an update?