Angular 6 issues? Please add a @NgModule annotation.
See original GitHub issueUnexpected value 'ChartistModule in 'node_modules/ng-chartist/bundles/ng-chartist.umd.js' imported by the module 'DashboardModule in 'dashboard.module.ts'. Please add a @NgModule annotation.
I get this error now when i try to use Chartist in a Angular 6 project. I have tried with the various suggestions in this https://github.com/willsoto/ng-chartist/issues/94 but i’m not sure how related they are.
I have also had a look at https://github.com/willsoto/ng-chartist/issues/124 but tbh i don’t understand any of it 😃
It works when i run locally but the build command fails. It works fine in a previous project that is not running Angular 6.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:19 (5 by maintainers)
Top Results From Across the Web
Angular error: Please add a @NgModule annotation
You're trying to "import" a component in SomeModule . imports: [ CommonModule, SomeComponent ], You import modules and declare components, ...
Read more >Please add a @NgModule annotation in AOT Compilation #355
A workaround is now to just reference TypeScript barrels with an explicit /index . It would be best if ng-packagr made it unneeded...
Read more >Angular Error on build: 'Please add a @NgModule annotation'
Hi,. I'm using Angular 6 with the latest SpreadJS demo. When trying to build to production, I get the following error:
Read more >Angular error: Please add a @NgModule annotation-angular.js
You're trying to "import" a component in SomeModule . imports: [ CommonModule, SomeComponent ],. You import modules and declare components, which is exactly ......
Read more >Error message Is it missing @NgModule annotation? NG6002
https://codedocu.com/Net-Framework/ASP_dot_Net-Core/ Angular /Errors/ Angular -Error_colon_-Is-it-missing-an-@ NgModule - annotation ?2672Error ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
hey willsoto,
there is actually no chance to create a aot production build…
Unexpected value 'ChartistModule in 'node_modules/ng-chartist/bundles/ng-chartist.umd.js' imported by the module 'SharedModule in 'shared.module.ts'. Please add a @NgModule annotation.
With Angular 6 and CLI, that worked for me: ng build --prod --aot=false --build-optimizer=false