No. Chrome Apps for Mobile are first-class native apps that run independent of the Chrome Browser. They are hybrid apps, which means they leverage a WebView component, not the Chrome Browser, to display content within the Android/iOS application.
- Android: Crosswalk WebView is bundled by default, but you can choose to use the system WebView. See our Crosswalk documentation for more information.
- iOS: UIWebView.
How are Chrome Apps for Mobile distributed to users? Are they installed through the Chrome Web Store?
Chrome Apps for Mobile are first-class native apps and distributed by publishing to the Play Store (Android) or App Store (iOS). They are not installed from the Chrome Web Store.
Chrome Apps for Mobile are actually built on top of Apache Cordova, and most of our work has gone directly into that project.
Core web features vary by the underlying WebView (e.g. iOS 6 vs iOS 7 vs Android vs Crosswalk).
Chrome API support is tracked within APIsAndLibraries.md.
No. However, you can still compile and use native code by writing a custom Cordova plugin.
- Support both desktop and mobile!
- Background page & lifecycle events
- A more opinionated workflow
- More reasons: Stack Overflow
Yes. Read their documentation, though, as some plugins may require additional configuration when used outside of a mobile Chrome App.
Yes. cca
forwards commands to cordova
, so the following will work:
cca plugin add [PLUGIN_ID or GIT_URL or LOCAL_PATH]
One caveat though - when using cca push
and the Chrome App Developer Tool, only plugins built into the tool will be avaiable.
npm install -g cca
File a GitHub Issue.
By default, cca
uses a bundled WebView (Crosswalk), rather than the system WebView.
On pre-L devices, Crosswalk provides much better performance and a newer web runtime than the stock Android WebView. However, there are [tradeoffs](https://github.com/MobileChromeApps/mobile-chrome-apps/blob/master/docs/Crosswalk.md
As of [email protected]
(March 2015), CCA apps have use the same Content-Security-Policy as desktop Chrome Apps.
No. However, if you have a use-case for wanting to, we'd love to hear about it. :).
- Android with Crosswalk: Polymer works without the need for polyfills.
- Android without Crosswalk:
- pre-KitKat: Polymer does not work.
- KitKat: Polymer works and requires its polyfills.
- Android L+: Polymer works without the need for polyfills.
- iOS 6, 7, 81: Polymer works and requires its polyfills.
1 Cordova support for WKWebView is still under development.
Chrome apps on both mobile and desktop require using the
vulcanize tool with the --csp
flag.
Neither chrome.storage.sync
nor chrome.syncFileSystem
are supported within CCA. However, you can use chrome.identity
to obtain a Google auth token, and use that with the Drive API to sync files.
See Stack Overflow answer: http://stackoverflow.com/questions/21673797/set-status-bar-color-using-chrome-mobile-apps/
Generally, it's best to check in only files that you've edited, and not those generated by cca
. In addition, it's helpful to use a script or README instructions that will create the Cordova workspace based on what you have checked in. E.g.:
cca create GeneratedProject --link-to=/path/to/project/src
Use the Chrome Dev Editor when:
- You cannot (or do not want to) install Node or Android/iOS SDKs
- You would like an IDE that helps with Chrome App development
- You are developing on a Chromebook
Use cca
when:
- You want to create
.apk
or.ipa
files for uploading to the Play Store / App Store - You would like to add custom Cordova plugins or make edits to native code
- You would like a command line tool to go along with your editor of choice
Aside from that, use whichever you prefer. Using them interchangeably on the same source directory will work just fine. :)
Xcode and Android Studio: yes.
Eclipse: No (since it doesn't support Android's gradle build system)
Using Xcode and Android Studio is often really useful when developing your own Cordova plugins. Use the Xcode / Android Studio project files within the platforms/ios
and platforms/android
directories respectively. BUT REMEMBER! When making edits to files within these IDEs, you will be editing copies of the files that are clobbered when running cca
commands.