-
Notifications
You must be signed in to change notification settings - Fork 311
Issue #1309 Can't resolve './app.module.ngfactory' is still present for many of us #1315
Comments
@mburger81 -- This error literally tells you the issue. You need to add the HomePage class (src/pages/home.ts) to the src/app/app.module.ts in the declarations and entryComponents arrays. This is because in ng5, all components Your app.module.ts will then look like this:
|
@chrisvanderkooi thx but are you kidding me? So sorry, thx for your intention to help, but your post is completly wrong! Thx 👍 Bug is still there and meantime there is another open bug! #1317 |
+1 I'm dealing with the same problem. I've been stucked for a week with this and still can't find a solution. Everything works ok when I run but when I run i get the following error: What i found strange is that I started a new ionic app with However, when I started a new app with the "super" template, without doing any modification in the code, I got the same error output when trying to run with --prod flag. Does anyone know how can I overcome this? Thanks in advance |
@lucastelnovo Take a look at this |
This is fixed in Thanks, |
Short description of the problem:
As described several days ago in post #1309 the bug is still present for many of us, we did many posts there also I created a repo to reproduce the scenario. Perhaps it is better I create a new one because the other one is closed, so this is what I have wrote there:
On my linux machine It's really simple to simulate the bug which for me still persists.
I created an empty ionic project with
ionic start
selecting theblank
starter template.After that I remove the
Home
component fromapp.module.ts
, this component is not loaded and the build script should give errorI created a repo to help you:
https://github.com/mburger81/ionic-ng5-bug
On running
./node_modules/.bin/ngc
I get this errorError: Cannot determine the module for class HomePage in ~/ionic-ng5-bug/src/pages/home/home.ts! Add HomePage to the NgModule to fix it.
On running ionic
cordova build android --prod --release
I get always the same errorThis is my environment:
Edit:
I updated also to latest
Node LTS version 8.9.1
with the same resultThe text was updated successfully, but these errors were encountered: