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

Ng2Permission is not an NgModule #9

Open
vrudikov opened this issue Oct 30, 2017 · 2 comments
Open

Ng2Permission is not an NgModule #9

vrudikov opened this issue Oct 30, 2017 · 2 comments

Comments

@vrudikov
Copy link

vrudikov commented Oct 30, 2017

Angular version: ^4.3.5
Angular CLI version: ^1.4.2

ERROR in Error: Ng2Permission is not an NgModule
at _getNgModuleMetadata (/Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_impl.js:140:15)
at _extractLazyRoutesFromStaticModule (/Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_impl.js:109:26)
at /Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_impl.js:129:27
at Array.reduce (native)
at _extractLazyRoutesFromStaticModule (/Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_impl.js:128:10)
at Object.listLazyRoutesOfModule (/Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_impl.js:53:22)
at Function.NgTools_InternalApi_NG_2.listLazyRoutes (/Users/xxx/project/node_modules/@angular/compiler-cli/src/ngtools_api.js:91:39)
at AotPlugin._getLazyRoutesFromNgtools (/Users/xxx/project/node_modules/@ngtools/webpack/src/plugin.js:207:44)
at _donePromise.Promise.resolve.then.then.then.then.then (/Users/xxx/project/node_modules/@ngtools/webpack/src/plugin.js:443:24)
at process._tickCallback (internal/process/next_tick.js:103:7)
@HariAlexiev
Copy link

I have similar problem.. but only when I use "ng build --prod"

RROR in : Unexpected value 'Ng2Permission in ...../node_modules/angular2-permission/dist/module/ng2-permission.module.d.ts' imported by the module 'AppModule in ..../src/app/app.module.ts'. Please add a @NgModule annotation.

w/out the --prod flag is working correctly.

Any ideas ?

@HariAlexiev
Copy link

Actually it seems to be related to AOT flag, if it is set to false the build is OK...

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

2 participants