简体   繁体   中英

Failed to compile angular application

I try to compile my Angular application and I get this:

Failed to compile.

./node_modules/@angular/material/esm5/core.es5.js Module not found: Error:
  Can't resolve '@angular/cdk/a11y' in '/media/DATOS/CBA/desafio/
  desafio_FED/node_modules/@angular/material/esm5'

Please, help me ;)

Your error message:

Module not found: Error: Can't resolve '@angular/cdk/a11y' in '/media/DATOS/CBA/desafio/desafio_FED/node_modules/@angular/material/esm5'

tells me your @angular/material/esm5 module couldn't resolve it's required dependency of @angular/cdk/a11y and it needs this module to do its job.

Maybe you could try installing that specific module and see if that resolves your issue:

npm i @angular/cdk --save

Hopefully that helps!

You should make sure that you have below dependencies installed in your project, if not:

Clean your npm cache ( npm cache clean --force ) and run

    npm install --save @angular/material

    npm install --save @angular/cdk

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM