版本:
Ionic 4,type = Angular,cordova v7.0.0
当我尝试运行命令时:ionic cordova运行android 我的应用程序可以在模拟器(设备版本7.1 API 25)中完美运行,但是当我尝试将应用程序安装到具有4.4.2(API 19)版本的物理设备上时,却看到了空白屏幕。
在我的config.xml文件中,我看到了:
<engine name="android" spec="^6.2.3" />
我该怎么办?
使用android studio调试的其他详细信息:
02/22 13:30:32: Launching android
No apk changes detected since last installation, skipping installation of C:\Ionic\testApp\platforms\android\build\outputs\apk\android-debug.apk
$ adb shell am force-stop io.ionic.starter
$ adb shell am start -n "io.ionic.starter/io.ionic.starter.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER -D
Connecting to io.ionic.starter
Capturing and displaying logcat messages from application. This behavior can be disabled in the "Logcat output" section of the "Debugger" settings page.
V/Provider/Settings: get setting for user 0 by user 0 so skipping cache
invalidate [system]: current 297 != cached 0
D/ActivityThread: hoder:android.app.IActivityManager$ContentProviderHolder@42ed8968,provider,holder.Provider:android.content.ContentProviderProxy@42ed90e0
V/Provider/Settings: from db cache, name = anr_debugging_mechanism , value = 1
D/asset: AssetManager-->addDefaultAssets CIP path not exsit!
W/ActivityThread: Application io.ionic.starter is waiting for the debugger on port 8100...
I/System.out: Sending WAIT chunk
I/dalvikvm: Debugger is active
A/libc: Fatal signal 11 (SIGSEGV) at 0x0000000a (code=1), thread 18688 (o.ionic.starter)
答案 0 :(得分:0)
尝试在polyfills.ts
中启用这些导入:
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
import 'core-js/es6/math';
import 'core-js/es6/string';
import 'core-js/es6/date';
import 'core-js/es6/array';
import 'core-js/es6/regexp';
import 'core-js/es6/map';
import 'core-js/es6/weak-map';
import 'core-js/es6/set';
为我工作:)