Chrome Apps Run On iOS and Android
Written by Ian Elliot   
Thursday, 30 January 2014

This is a strange story. Web apps run anywhere there is a browser, but now Google has introduced a new twist on the "run anywhere" idea. Chrome apps that run on iOS and Android. What does this mean?

Once, what seems like a very long time ago, the web presented us with a huge opportunity. The standard web browser could act as a universal programming platform. All we had to do was write a program once and it could work on any OS that supported the browser. For many reasons this never quite worked out but now all of the big browser makers seem to see that it makes sense. 

Google's very late attempt to allow web apps to run anywhere with the same or similar power to desktop apps finally managed to get up enough enthusiasm to make Chrome apps work on the desktop. 

So what is a Chrome app?

It is essentially a Web app, i.e. HTML/JavaScript/CSS plus some additional APIs and a packaging format that includes a manifest. Some of the APIs are standard, but there are enough differences to mean that a Chrome app only runs under the Chrome browser or under the ChromeOS. So much for the dream of web apps that run on any system. If you create a Chrome app it will run on any system that runs Chrome. If you don't want to use Chrome as your browser then you need to use some other form of Web app - say Mozilla's Open Web app.

PhoneGapIcon

 

The latest move extends the reach of Chrome apps to iOS and Android by way of the sneaky trick of using Apache Cordova, aka PhoneGap. This is a sneaky trick because you can already use Cordova to run very standard Web apps on iOS, Android and a range of other mobile operating systems.

 

So why bother with a Chrome app? 

The simple answer is that Google has made a range fo the core Chrome APIs available which means if you basically just restrict what you are working with to the Chrome APIs you can port your Chrome app very quickly. Of course, you also have access to all of the Cordova APIs as well - but if you use any of them you no longer have a pure Chrome app. 

The Chrome APIs that are available include: 

  • identity - sign-in users using OAuth2 without prompting for passwords
  • payments (currently Android only) - sell virtual goods within your mobile app
  • pushMessaging - push messages to your app from your server
  • sockets - send and receive data over the network using TCP and UDP
  • notifications (currently Android only) - send rich notifications from your mobile app
  • storage - store and retrieve key-value data locally
  • syncFileSystem - store and retrieve files backed by Google Drive
  • alarms - run tasks periodically

Currently the pushMessaging and syncFileSystem APIs are only beta quality. There is a longer list of Chrome APIs, including NaCl, that seem to be on a list to be supported at some point in the future. 

What makes it all easy is a new toolchain that wraps the Chrome App as a native application using Cordova. Once wrapped the app can be run on a real device or an emulator. 

Once you have your native app you can submit it for inclusion in the appropriate app store. You are going to have no problems with the Android app store but iOS? What will Apple make of Chrome apps running on iOS? 

chromeIcon

 

At the moment there are too many people with an interest in keeping app development fragmented and too few who see the advantage in a unified platform.

 

More Information

Run Chrome Apps on mobile using Apache Cordova

Mobile Chrome Apps

Related Articles

Chrome Apps Go Public       

Adobe PhoneGap 3.0 Released       

PhoneGap 2.0 Released

Getting started with PhoneGap

PhoneGap 1.0 - the smart way to create apps? 

Chrome Gets Desktop App Launcher

Mozilla-Style Web Apps With Mortar

Try Firefox OS On the Desktop  

The Disastrous Fragmentation Of Web Apps

Creating Web Apps - The Camera API

 

To be informed about new articles on I Programmer, install the I Programmer Toolbar, subscribe to the RSS feed, follow us on, Twitter, FacebookGoogle+ or Linkedin,  or sign up for our weekly newsletter.

 

espbook

 

Comments




or email your comment to: comments@i-programmer.info

Banner


Rust And C++ Should Be Friends?
20/11/2024

The Rust Foundation has just released a statement on Rust and C++ interoperability and Google is ponying up $1 to see that it gets done.



AI Breakthrough For Robot Surgery
17/11/2024

Using imitation learning, a robot has learned to perform surgical procedures as skillfully as human surgeons, bringing the field of robotic surgery closer to true autonomy.


More News

 

 

Last Updated ( Thursday, 30 January 2014 )