Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Angular 6: npm ERR! cb() never called when installing angular cdk

I am installing angular material here is what I have done

Angular material successfull installed by the following command

   1.npm install --save @angular/material 

Angula CDK fail to install by using the following command

  1.npm install --save @angular/cdk

I get the following error in cmd:

npm WARN tar zlib error: unexpected end of file
npm ERR! cb() never called!

npm ERR! This is an error with npm itself. Please report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Bonge\AppData\Roaming\npm-cache\_logs\2018-07-25T17_44_24_771Z-debug.log

Fo reference I never had this problem, this happend after I uninstalled the cdk and angular material so now I am trying to install it again ,

what do I need to do to solve this problem?

like image 221
The Dead Man Avatar asked Jul 25 '18 18:07

The Dead Man


2 Answers

After googling here is the solution i found

npm cache clean --force
like image 152
The Dead Man Avatar answered Oct 02 '22 13:10

The Dead Man


The best way to resolve is update the npm version and install again.

npm install -g npm

like image 36
user10471372 Avatar answered Oct 02 '22 11:10

user10471372