{"id":89,"date":"2011-10-10T16:09:34","date_gmt":"2011-10-10T16:09:34","guid":{"rendered":"http:\/\/new.tola.me.uk\/blog\/2011\/10\/10\/keeping-web-apps-open\/"},"modified":"2011-10-10T16:09:34","modified_gmt":"2011-10-10T16:09:34","slug":"keeping_web_apps_open","status":"publish","type":"post","link":"https:\/\/tola.me.uk\/blog\/2011\/10\/10\/keeping_web_apps_open\/","title":{"rendered":"Keeping Web Apps Open"},"content":{"rendered":"<p><em>Reposted from webian.org<\/em><\/p>\n<p><strong>The Universal App Platform<br \/> <\/strong><\/p>\n<p>The best thing about web apps is that they can run on any platform.  This is because they use a set of open standards which are universally  supported. The latest incarnations of these standards like HTML5 and  CSS3 are more powerful than ever and it seems inevitable to me that the  web will eventually win out as the open, universal app platform.<\/p>\n<p>The current generation of popular desktop operating systems like  Windows 7, OS X and Linux and mobile operating systems like iOS, Android  and Windows Phone treat web apps as second class citizens, inferior to  their native platform-specific counterparts. But that&#39;s all set to  change.<\/p>\n<p>Microsoft <a href=\"http:\/\/windows.microsoft.com\/en-US\/windows-8\/preview\">Windows 8<\/a>, Google <a href=\"http:\/\/www.chromium.org\/chromium-os\">Chrome OS<\/a>, The Linux Foundation&#39;s <a href=\"https:\/\/www.tizen.org\/\">Tizen<\/a> and Mozilla <a href=\"https:\/\/wiki.mozilla.org\/B2G\">B2G<\/a> will all join <a href=\"http:\/\/webian.org\/\">Webian<\/a> in putting web apps centre stage, as the preferred category of app on their respective platforms.<\/p>\n<p><strong>Fragmentation<\/strong><\/p>\n<p>Thanks to HTML5 and related standards web apps are already pretty  powerful, but there is still some way to go before web apps can do  everything that native apps can do. On mobile platforms new APIs are  needed for access to telephony, messaging and cameras for example, and  some kind of &quot;app store&quot; style distribution and installation mechanism  is likely to be needed to provide a more app-like experience.  &quot;Installing&quot; a web app is a little like bookmarking a web site and can  provide an opportunity for the app to ask the user for all the  permissions it needs up-front, download any resources which will be  needed for offline use and perhaps add an shortcut icon to an app list.<\/p>\n<p>Because there aren&#39;t currently established standards for all of these  features, each platform is intially rolling its own approach. Apps for  Chrome OS can only be found via Google&#39;s own &quot;<a href=\"https:\/\/chrome.google.com\/webstore\">Chrome Web Store<\/a>&quot;,  you have to have a Google Account to install them and many of the apps  found there will only work in Chrome. Windows 8 will have a set of APIs  for its new Metro user interface, but apps written for Metro won&#39;t  necessarily work on other platforms. We don&#39;t yet know much about Tizen,  but previous mobile platforms like HP&#39;s WebOS and the MeeGo Web Runtime  have also had platform-specific APIs.<\/p>\n<p><strong>An Open Approach<br \/> <\/strong><\/p>\n<p>Mozilla is also working on a new set of web APIs, but in line with  their mission of promoting openness on the web they&#39;re doing so in a  more open way. You can see the progress of their\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=673923\">APIs<\/a> for\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=674726\">telephony<\/a>,\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=674725\">messaging<\/a> (SMS),\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=678694\">battery<\/a>,\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=690056\">visibility<\/a>,\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=678695\">settings<\/a>,\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=681009\">power management<\/a> and\u00a0<a href=\"https:\/\/bugzilla.mozilla.org\/show_bug.cgi?id=674720\">contacts<\/a> on Bugzilla. These new APIs on Mozilla&#39;s core platform are the first step towards a new mobile OS from Mozilla called <a href=\"https:\/\/wiki.mozilla.org\/B2G\">B2G<\/a>  or &quot;Boot to Gecko&quot;. B2G will have a highly customisable UI built  entirely with web technologies and will allow for the installation of <a href=\"https:\/\/apps.mozillalabs.com\/\">Open Web Apps<\/a>,  as proposed by Mozilla Labs. With Open Web Apps, anyone can run their  own app store or directory and the aim is to create cross-platform  installable web apps.<\/p>\n<p>Mozilla is also collaborating with Google on &quot;<a href=\"http:\/\/mozillalabs.com\/blog\/2011\/07\/web-apps-update-experiments-in-web-activities-app-discovery\/\">Web Activities<\/a>&quot; or &quot;<a href=\"http:\/\/www.webintents.com\/\">Web Intents<\/a>&quot;  which could provide a standard mechanism for apps to call other apps  for certain functions. This collaboration is a promising sign because  Mozilla can not define standards on their own and will need to  co-operate with other browser &amp; OS vendors.<\/p>\n<p><strong>Towards Standards<\/strong><\/p>\n<p>There are already standardisation efforts in this area at the W3C such as the <a href=\"http:\/\/www.w3.org\/2009\/dap\/\">Device APIs Working Group<\/a> and the <a href=\"http:\/\/www.w3.org\/TR\/widgets\/\">Widget Packaging and XML Configuration<\/a> recommendation, but W3C recommendations are not always in line with what the implementors (browser &amp; OS vendors) are doing.<\/p>\n<p>For example, W3C Widgets provide a mechanism for installing a  &quot;widget&quot; locally on a device by packaging up all of its resources in a  zip file, including an XML manifest file. The specification was used for  widgets in the Opera browser but when the MeeGo Web Runtime tried to  use it as a method of installing fully fledged web apps it didn&#39;t work  out very well.<\/p>\n<p>Mozilla and Google are taking a different approach to installable web  apps, both choosing to use a JSON manifest file and rely to a large  extent on HTML5&#39;s offline capabilities for caching and updating offline  resources. Even these two similar implementations have <a href=\"https:\/\/groups.google.com\/d\/topic\/mozilla-labs\/Tz4pM4JjuI8\/discussion\">subtle differences<\/a>  which make them incompatible with each other so there&#39;s a real need for  standardisation in this area if we&#39;re to have cross-platform  installable web apps.<\/p>\n<p><strong>Hosted vs. Packaged<\/strong><\/p>\n<p>One slightly odd trend in the standardisation of &quot;web apps&quot; is the  tendency to focus on &quot;packaging&quot; apps rather than &quot;hosting&quot; them. This  seems to be an attempt to emulate the way mobile and desktop apps  currently work by bundling up all of the app&#39;s resource in a &quot;package&quot;  which is downloaded and installed locally. The whole package then needs  to be updated every time any of the resources change. This seems odd to  me because this isn&#39;t the way the web usually works and it doesn&#39;t seem  very web-like at all.<\/p>\n<p>The fact that an individual resource can be identified by a URI is  what makes it a part of the web, so to package resources up in one big  bundle to be downloaded and used locally seems to break the web paradigm  and therefore these apps are not &quot;web apps&quot; in my view, just apps  downloaded over the web. This is how W3C widgets work and it&#39;s also how  Chrome &quot;packaged&quot; apps work and seems to be the direction of the <a href=\"http:\/\/www.wacapps.net\/\">Wholesale Apps Community<\/a>, the EU funded <a href=\"http:\/\/webinos.org\/\">Webinos<\/a> project and the <a href=\"http:\/\/www.w3.org\/community\/native-web-apps\/\">Native Web Apps<\/a> community on the W3C web site.<\/p>\n<p>For an app to be part of the web, I think all of its resources (HTML,  CSS, JavaScript, images etc.) must be identifiable by a URI. Resources  which are needed when operating offline can be marked as such in an  HTML5 cache manifest, which then also provides an automatic update  mechanism when these resources are changed. This maintains one of the  great characteristics of web apps which is their ability to be updated  seamlessly with new features and bugfixes without the user having to  manually upgrade to a new version. Mozilla Open Web Apps seem to work in  this way, and so do Chrome&#39;s &quot;hosted&quot; apps.<\/p>\n<p><strong>Conclusions<\/strong><\/p>\n<p>It seems that web apps will be the preferred category of apps for a  whole new generation of operating systems, but in order for these web  apps to remain cross-platform new open standards must be agreed upon for  APIs which give web apps all the power of native apps.<\/p>\n<p>A mechanism for the discovery, installation and updating of <em>hosted<\/em>  installable web apps and a trust framework which allows for secure open  distribution is also something which I think desperately needs  standardisation if the vision of a universal open web app platform is to  be realised.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Reposted from webian.org The Universal App Platform The best thing about web apps is that they can run on any platform. This is because they use a set of open standards which are universally supported. The latest incarnations of these standards like HTML5 and CSS3 are more powerful than ever and it seems inevitable to &hellip; <a href=\"https:\/\/tola.me.uk\/blog\/2011\/10\/10\/keeping_web_apps_open\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Keeping Web Apps Open<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-89","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/posts\/89","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/comments?post=89"}],"version-history":[{"count":0,"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/posts\/89\/revisions"}],"wp:attachment":[{"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/media?parent=89"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/categories?post=89"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tola.me.uk\/blog\/wp-json\/wp\/v2\/tags?post=89"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}