Description
Angular does not support optimizing (or even finding missing) imports for standalone components. Ideally there would be tooling that removes unused imports and consistently reports missing imports. For those familiar with the internals of angular-eslint
, would this be possible or even make sense to add?
Related issues from the angular
repo:
angular/angular#46351
angular/angular#46766
In my experience, the angular builder only catches some missing imports and will cause the build to fail. There are many scenarios where an obvious import is missing and it builds successfully. I can only rely on WebStorm's Angular - undefined binding inspection to accurately catch missing imports. I keep a WebStorm license just because of this checker.
I do not know of anything that can find unused imports. WebStorm has a feature request.