Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Angular 11 support #63

Open
coyoteecd opened this issue Nov 26, 2020 · 2 comments
Open

Angular 11 support #63

coyoteecd opened this issue Nov 26, 2020 · 2 comments

Comments

@coyoteecd
Copy link

Tried upgrading a project that uses ng2-trim-directive to Angular 11 and I see the following error during build:

Error: node_modules/ng2-trim-directive/dist/input-trim.module.d.ts:1:22 - error NG6002: Appears in the NgModule.imports of AuthenticationModule, but could not be resolved to an NgModule class.

This likely means that the library (ng2-trim-directive) which declares InputTrimModule has not been processed correctly by ngcc, or is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.
@Patrickkk
Copy link

I ended up simply copying the source code of the directive into our project. Just copy the file https://github.com/anein/angular2-trim-directive/blob/master/src/input-trim.directive.ts and be done with it ;)

@anein
Copy link
Owner

anein commented Jun 4, 2021

Pretty nice and simple life-hack! =)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants