0

I did ng serve on my Terminal with code opened in Visual Studio Code. And i got output -

  ** NG Live Development Server is listening on localhost:4200, open 
  your browser on http://localhost:4200 **
   10% building modules 4/4 modules 0 active

And it didn't go beyond 10%. I was also getting error -

 Your global Angular CLI version (6.2.5) is greater than your local
 version (1.3.0). The local Angular CLI version is used.

 To disable this warning use 
 "ng config -g cli.warnings.versionMismatch false".

So i ran these commands for angular 4 -

 npm install --save-dev @angular/cli@1.4.10
 npm install
 ng -v 

o/p -

Your global Angular CLI version (6.2.5) is greater than your local
version (1.4.10). The local Angular CLI version is used.

 To disable this warning use "ng config -g 
 cli.warnings.versionMismatch 
 false".
    _                      _                 ____ _     ___
   / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
  / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
 / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
/_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
               |___/

@angular/cli: 1.4.10
node: 8.9.4
os: linux x64
@angular/common: 4.3.4
@angular/compiler: 4.3.4
@angular/core: 4.3.4
@angular/forms: 4.3.4
@angular/http: 4.3.4
@angular/platform-browser: 4.3.4
@angular/platform-browser-dynamic: 4.3.4
@angular/router: 4.3.4
@angular/upgrade: 4.3.4
@angular/cli: 1.4.10
@angular/compiler-cli: 4.3.4
typescript: 2.4.2

Now i again ran -

      ng serve

And still my angular processor doesn't go beyond 10%-

** NG Live Development Server is listening on localhost:4200, open 
 your browser on http://localhost:4200/ **
 10% building modules 3/3 modules 0 active

Please help.

Gonçalo Peres
  • 11,752
  • 3
  • 54
  • 83
Techdive
  • 997
  • 3
  • 24
  • 49
  • have you tried downgrading you global angular-cli version? https://stackoverflow.com/questions/39826902/i-want-to-downgrade-angular-cli-globally-as-my-project-is-using-older-version-of – tcrite Oct 17 '18 at 11:51
  • I think because my computer cpu process is slow. It is compiling after a long time. Thanks – Techdive Oct 17 '18 at 12:15

1 Answers1

0

you have to Increasing the amount of inotify watchers

you can set a permanent new limit by executing this line

echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf

Ref: Angular-cli ng serve livereload not working

Rakesh Chand
  • 3,105
  • 1
  • 20
  • 41