-
Notifications
You must be signed in to change notification settings - Fork 96
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
Unexpected value 'CKEditorModule' imported by the module 'AppModule'` #50
Comments
Having the same error, when using Webpack. With SystemJS everything is working fine. Later: Had to fix this issue, and what I did is copy the module and the component from the src file inside my project, then done some small edits (had some highlighting issues like @input() config: any;) and then imported from the global scope CKEDITOR using: declare const CKEDITOR: any; Last step was to import the module from the new location and the error has gone... my guess is how has been exported eg: export * from '...' and maybe should have been export {CKEditorComponent} from '..' as per eg: angular/angular-cli#1831 (comment) |
Hi! The compiler verifies that each module is truly a module by checking that the object provided has a metadata object that is an instance of DecoratorFactory as defined in The problem happens when the CKEditorModule's metadata object is instead an instance of DecoratorFactory as defined in another file: In short, the issue arises from CKEditorModule using its own, separate copy of angular core, when loaded via WebPack. This explains why LeonardCModoran's workaround worked: copying the Ng2CKEditor code into his project ensured that it used the same angular core as the rest of his code. That's as far as I'll go unfortunately. I haven't studied how to develop and publish shareable components or libraries in Ng2, so I haven't got a clue how to fix this. Hopefully someone can take it from there? Update: |
Can someone please share a reproduction repo on github ? I'll try to fix this soon, and repo can help some people in #54 Thanks ! |
Hi, |
Hi, Just now I updated to 1.1.5 and it installed just fine, without the incriminated subdir. |
thanks @Nandan108 ! |
Uncaught Error: Unexpected value 'CKEditorModule' imported by the module 'AppModule'
After installing & importing in my app module.
Any ideas?
The text was updated successfully, but these errors were encountered: