Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

ESLint: Error: Failed to load config "plugin:@angular-eslint/ng-cli-compat" to extend from

Tags:

npm

angular

I have tried updating an Angular project from version 15 to 16, now I get several errors that I can't make sense of. IntelliJ shows the following error at the top:

enter image description here

I don't know if it's related, but running ng serve also fails with many module errors where I can't really see what's wrong. Mostly it says

NG6002: This import contains errors, which may affect components that depend on this NgModule.

enter image description here

does anyone have a suggestion how to fix that?

like image 858
Maxim Avatar asked Dec 06 '25 18:12

Maxim


2 Answers

I just removed the references to the below plugins in .eslint.json under extends section

"plugin:@angular-eslint/ng-cli-compat",
"plugin:@angular-eslint/ng-cli-compat--formatting-add-on",

and added the below

"plugin:@angular-eslint/recommended"

The extends now looks as below

"extends": [
   "plugin:@angular-eslint/recommended",
   "plugin:@angular-eslint/template/process-inline-templates"
],
like image 127
Alex Ryltsov Avatar answered Dec 08 '25 09:12

Alex Ryltsov


ng-cli-compat was removed you have to follow instructions here: https://github.com/angular-eslint/angular-eslint/issues/1353#issuecomment-1529924573

like image 43
kemsky Avatar answered Dec 08 '25 09:12

kemsky



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!