启动屏幕后,我的应用需要很长时间才能加载

时间:2019-05-22 15:48:36

标签: ionic-framework ionic3

启动画面后,白屏显示约20秒钟,然后显示主页。 然后,我尝试使用以下方法构建我的应用程序:

ionic cordova  build android --prod --release

该应用程序加载速度非常快,但大多数插件均无法正常运行(本机存储和admob)。我的配置:

<?xml version='1.0' encoding='utf-8'?>
    <content src="index.html" />
    <access origin="*" />
    <allow-intent href="http://*/*" />
    <allow-intent href="https://*/*" />
    <allow-intent href="tel:*" />
    <allow-intent href="sms:*" />
    <allow-intent href="mailto:*" />
    <allow-intent href="geo:*" />
    <preference name="ScrollEnabled" value="false" />
    <preference name="android-minSdkVersion" value="15" />
    <preference name="BackupWebStorage" value="none" />
    <preference name="SplashMaintainAspectRatio" value="true" />
    <preference name="FadeSplashScreenDuration" value="300" />
    <preference name="SplashShowOnlyFirstTime" value="false" />
    <preference name="SplashScreen" value="screen" />
    <preference name="AutohideSplashScreen" value="false" />
    <preference name="SplashScreenDelay" value="6000" />
    <platform name="android">
        <preference name="loadUrlTimeoutValue" value="700000" />
        <allow-intent href="market:*" />
        <icon density="ldpi" src="resources/android/icon/drawable-ldpi-icon.png" />
        <icon density="mdpi" src="resources/android/icon/drawable-mdpi-icon.png" />

    </platform>
     <plugin name="cordova-android-support-gradle-release" spec="^2.0.1">
        <variable name="ANDROID_SUPPORT_VERSION" value="27.+" />
    </plugin>
    <plugin name="cordova-plugin-admob-free" spec="^0.13.0" />
    <plugin name="cordova-plugin-camera" spec="^3.0.0" />
    <plugin name="cordova-plugin-file" spec="^5.0.0" />
    <plugin name="cordova-plugin-file-transfer" spec="^1.7.0" />
    <plugin name="cordova-plugin-filepath" spec="^1.1.0" />
    <plugin name="cordova-plugin-ionic-webview" spec="^1.1.16" />
    <plugin name="cordova-plugin-nativeaudio" spec="^3.0.9" />
    <plugin name="cordova-plugin-nativestorage" spec="^2.3.2" />
    <plugin name="cordova-plugin-splashscreen" spec="^4.0.3" />
    <plugin name="cordova-plugin-whitelist" spec="^1.3.1" />
    <plugin name="ionic-plugin-keyboard" spec="^2.2.1" />
</widget>

0 个答案:

没有答案