I'm be in favour of adding the polyfill right to cordova.js. - I'd like to use setImmediate within the Android bridge code, and setImmediate make up about half of the Promise polyfill code. - The polyfill is quite small - Promises are a part of ECMAScript, have been adopted by multiple browsers, and are being used in several up-and-coming specs (service workers, file) - If we make it a part of core, we can start encouraging devs to write plugins that return them.
On Wed, Aug 13, 2014 at 8:29 AM, Michal Mocny <mmo...@chromium.org> wrote: > Libs like modernizr will polyfill Promises, but that seems heavy handed for > just this small library. > > My advice: when we want to write our first api that requires promises, we > create a separate plugin just for the Promise polyfill. Then, any api that > requires Promises can depend on the polyfill plugin. We've been using this > strategy for cca and has worked really well. > > -Michal > > > On Wed, Aug 13, 2014 at 4:56 AM, Axel Nennker <ignisvul...@gmail.com> > wrote: > > > Hi, > > > > newer W3C standards use Promises but I think that Promises are not > > implemented in the WebViews Cordova currently uses. > > > > Any advise on this? How should I implement a new W3C standard in Cordova? > > Are there examples already? > > > > kind regards > > Axel > > >