1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Cordova Android Crosswalk WebView Build Setting ハイブリッドアプリ

Last updated at Posted at 2016-06-16

Crosswalk Pluginをインストールしたら、デフォルトのWebViewを使わず、crosswalk webview使うになる。

  • 利点

  • ウェブ新機能を利用できる ...

  • 欠点

  • より多いメモリ使用 30MB

  • APK サイズ増える 20MB ...

Install

cordova plugin add cordova-plugin-crosswalk-webview

Build Setting

platform/android/build.gradle 編集

ext.cdvBuildMultipleApks = false // 40MB大きくなるけど、一つAPK生成できる。true にすると、二つAPKになる
...

android {
    dexOptions {
        javaMaxHeapSize "4g"  
    }
    ...
   defaultConfig {
     ...
     multiDexEnabled true
   }
   
   lintOptions {
      checkReleaseBuilds false // cdvBuildMultipleApks=trueの場合、release APK作成ため
      ...
   } 

dependencies {
    ...
    compile 'com.android.support:multidex:1.0.0'
}

platform/android/AndroidManifest.xml 編集

<application android:hardwareAccelerated="true"...> タグに属性追加
android:name="android.support.multidex.MultiDexApplication"

参考

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?