-
Notifications
You must be signed in to change notification settings - Fork 646
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
Cannot find module “.” after --prod --relase build in ionic 3 #4132
Comments
I'm seeing the same thing. I'm using Capacitor instead of Cordova. It looks like Ionic is extremely sensitive to versioning here. This is my setup:
And my dev dependencies are:
When I change the version on TypeScript, I get general errors and can't even run in debug mode, when I change the version on @ionic/app-scripts, same story. I suspect that there is some module that is being pulled in for production build optimisation that ins't being imported correctly or has a conflict, but I do not have the time to go and dig. |
Same problem here, can't downgrade typescript version since Firebase lib requires 3.x.x |
Same problem here, cannot downgrade typescript becuase of firebase lib. |
you just need to disable the AoT, from my experience. this is what I use:
|
Wow. I've been searching for how to address this exact error for almost a week now. And I find a solution posted 19 minutes ago? That's amazing. |
@oborudko @NimaiMalle thank you! How can I run prod build with aot=false? My @ionic/app-scripts is 3.2.4 and I am on ionic v3 (ionic-angular 3.9.2) Thank you! |
@musla I'm not an expert on this stuff at all, so I hope someone else comments as well. Indeed, the build logs at the end say, "dev build finished", and I'm not sure what that means in terms of the output of the build. It might just be what gets printed if there's no explicit I am currently looking at the "angularCompilerOptions" that can be specified in tsconfig.json. I just started looking at these, but I'm hoping that there's something more granular I can turn off or change which will let me use Please share if anyone has any luck! |
Do we know if anyone with Ionic 4 is experiencing the same issue? This just started for me about a week ago and I haven't been able to resolve it so far (using Ionic 3). |
For me, the problem was |
after several years with Ionic3 I am still a complete novice I have tried a bunch of things while hunting stackoverflow and my own logs so I am not 100% what fixed the problem
I have been able to build APK and run it just fine, however when I tried upload my PWA (ie. the web app) that's when I discovered this weird (deja vue) error Uncaught Error: Cannot find module "." I will probably revert from @ghost ridiculously huge ionic build line to my original
Please help me with this and Thank you. Perhaps someone can help me clarify what is the difference between these two build folders
my current package.json looks like this
My package.json has tons of "vulnerabilities" (somehow I hate this word) but I keep cruising along. Sorry for the details, but I have to spill my pain after this much "time-wasting" searches. |
I am trying to make my prod build work I am getting this error
After doing some research I found the type script version 3.2.3 might be causing this and I should downgrade to typescript@2.7.2 but When I downgrade my version it gives me this error
The Angular Compiler requires TypeScript >=3.1.1 and <3.3.0 but 2.7.2 was found instead
My Package.json is
Any Help Would be appreciated
The text was updated successfully, but these errors were encountered: