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

Build with aot broken #5

Closed
ghost opened this issue Apr 24, 2017 · 2 comments
Closed

Build with aot broken #5

ghost opened this issue Apr 24, 2017 · 2 comments

Comments

@ghost
Copy link

ghost commented Apr 24, 2017

Hi!

Using angular-cli and running ng build --prod will give error:

ERROR in Internal error: unknown identifier {}
ERROR in ./src/main.ts
Module not found: Error: Can't resolve './$$_gendir/app/app.module.ngfactory' in '/home/usr/Projects/mangol/src'
@ ./src/main.ts 5:0-81
@ multi ./src/main.ts

It doesn't happen with ng build --aot=false --prod

Any solutions?

@ghost
Copy link
Author

ghost commented May 15, 2017

@fegyi001 do you plan to fix it with next release? AOT option true is very important for my production environment.

Thanks!

@fegyi001
Copy link
Owner

fegyi001 commented Jul 3, 2017

@NoCodeNoMore I upgraded Mangol to the latest dependencies whenever possible (Angular 4.2.5, Angular-cli 1.2.0). Then I created a new angular-cli project, added Mangol as described in the Readme, and the aot production building now works fine for me.

Try it like this:

ng build --env=prod --aot=true
Here is my output: http://imgur.com/a/q7C9f

@fegyi001 fegyi001 closed this as completed Jul 3, 2017
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

1 participant