Unexpected value xxx imported by the module xxx Please add a @NgModule annotation

这一生的挚爱 提交于 2019-12-11 18:12:28

问题


I'm attempting to convert an existing Angular app from 5.2.5 to 6.0.8. After some time struggling with an error, I've created a relatively straightforward repro which can be found here:

https://github.com/DelphiWorlds/Angular6Issue

The error on my machine comes out as:

ERROR in : Unexpected value 'TestModule in C:/Source/angular6issue/test/app/node_modules/test-package-a6/dist/index.d.ts' imported by the module 'AppModule in C:/Source/angular6issue/test/app/src/app/app.module.ts'. Please add a @NgModule annotation.

Edit: Note that it's just building for production that I'm having an issue with - it builds and runs fine in dev mode

来源:https://stackoverflow.com/questions/51147293/unexpected-value-xxx-imported-by-the-module-xxx-please-add-a-ngmodule-annotatio

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!