Hello, if I compile my App with ionic cordova build android --prod I get an error in my console log saying the following:
Unhandled Promise rejection: StaticInjectorError(n)[t -> e]:
StaticInjectorError(Platform: core)[t -> e]:
NullInjectorError: No provider for e! ; Zone: <root> ; Task: Promise.then ; Value: Error: StaticInjectorError(n)[t -> e]:
StaticInjectorError(Platform: core)[t -> e]:
NullInjectorError: No provider for e!
at t.get (vendor.js:1)
at vendor.js:1
at _ (vendor.js:1)
at t.get (vendor.js:1)
at vendor.js:1
at _ (vendor.js:1)
at t.get (vendor.js:1)
at re (vendor.js:1)
at t.get (vendor.js:1)
at Te (vendor.js:1) Error: StaticInjectorError(n)[t -> e]:
StaticInjectorError(Platform: core)[t -> e]:
NullInjectorError: No provider for e!
at t.get (file:///android_asset/www/build/vendor.js:1:58192)
at file:///android_asset/www/build/vendor.js:1:10256
at _ (file:///android_asset/www/build/vendor.js:1:10280)
at t.get (file:///android_asset/www/build/vendor.js:1:58973)
at file:///android_asset/www/build/vendor.js:1:10256
at _ (file:///android_asset/www/build/vendor.js:1:10280)
at t.get (file:///android_asset/www/build/vendor.js:1:58973)
at re (file:///android_asset/www/build/vendor.js:1:25967)
at t.get (file:///android_asset/www/build/vendor.js:1:108151)
at Te (file:///android_asset/www/build/vendor.js:1:31315)
I’ve never needed to import Platform
from ionic-angular
to providers
and this isn’t happening if I compile with --prod
My Ionic info is:
cli packages: (C:\...\node_modules)
@ionic/cli-utils : 1.19.3
ionic (Ionic CLI) : 3.20.1
global packages:
cordova (Cordova CLI) : 7.1.0
local packages:
@ionic/app-scripts : 3.1.10
Cordova Platforms : android 6.3.0
Ionic Framework : ionic-angular 3.9.2
System:
Android SDK Tools : 26.1.1
Node : v8.11.1
npm : 6.8.0
OS : Windows 10
Environment Variables:
ANDROID_HOME : C:\Users\...\AppData\Local\Android\Sdk
Misc:
backend : pro
What can be causing this?
Thanks