Objective
Cordova uses the embedded webview of the phone by default, while crosswalk uses the optimized chromium kernel's browser engine instead of the default WebView to achieve greater compatibility and performance gains.
Body
Using crosswalk in the Cordova project is very easy, just install a plugin on the line
Cordova Plugin Add Cordova-plugin-crosswalk-webview--save
Plug-in Project address: Https://github.com/infil00p/cordova-plugin-crosswalk-webview
The specific use method can consult the project document
In addition, crosswalk offers three modes of default, Shared, Lite
In short, the default mode provides all the functionality, each app has a separate packaged browser engine, while the sharing mode is that multiple apps share the same engine, only need to pack the engine at the first install, then not. Lite is a streamlined version of crosswalk, removing some of the less common features that make packaging smaller.
If you want to use Lite mode, the install command changes to
Cordova Plugin Add Cordova-plugin-crosswalk-webview--variable xwalk_mode= "Lite"--save
It is so simple, then prepare-build, after the packaging of the APK will be much larger than the original, if the original apk size is 10M, the default mode package of the APK will become about 30M, Lite mode around 20M.
End
If the app is running with Deveiceready not fire after 5 seconds error, then Cordova clean the project. In addition, crosswalk is mainly for Android platform optimization, although there are iOS version, but in fact, iOS Cordova performance is very good, so it is not necessary.
The crosswalk of Cordova study notes