0

My issue is, when I take pull from the git there is a angular project which have angular ^7.1.0, but my local global version is angular 8.

Your global Angular CLI version (8.3.5) is greater than your local
version (7.3.9). The local Angular CLI version is used.

What can be the solution for this?

Below is error screen-shot for the error when i run ng serve:

This usually happens because your environment has changed since running npm install. Run npm rebuild node-sass to download the binding for your current environment.

Error

Pathik Vejani
  • 4,263
  • 8
  • 57
  • 98

2 Answers2

0

Try to run npm rebuild node-sass

and re-run npm install again

  • Did you run 'npm rebuild node-sass' in your project folder or globally ? If you did it globally, try to run it inside of your project folder – Cedric Debot Dec 03 '19 at 08:22
0

Both your global and project's angular-cli version should be in sync. Try downgrading your global version or update the project's angular-cli version to avoid this error.

in your case can update the angular cli of your project to this latest using the command,

ng update @angular/cli

or uninstall the global angular cli and install specific version as per your need,

npm uninstall -g @angular/cli
npm cache verify
npm install -g @angular/cli@{version}

If you are not keen on updating, you could try using the global cli version in your local project using npm link by running the following command in your project,

npm link @angular/cli
Sasi Kumar M
  • 2,440
  • 1
  • 23
  • 23