An example is android-3.7.0 adding an extra prompt() on start-up that
retrieves a nonce from the native side. If any pre-3.7.0 were to use this
newer JS, it would likely show a prompt() on start-up.

The app plugin is not a real plugin only because we want it installed be
default.

I think the right thing to do here is to move platform-specific JS into the
platform repositories. This would be really nice from a
being-able-to-commit-dependent0-changes-in-one-commit standpoint as well.
Then, browserify will need to know to take modules from cordova-js, plugin
JS, as well as platforms/android/js-modules (we create this), when creating
cordova.js. We could avoid having multiple copies of files in the interim
by telling grunt where the platform is and actually delete the platform
files from cordova-js for both paths.

Sound right?



On Fri, Jan 9, 2015 at 5:58 PM, Steven Gill <[email protected]> wrote:

> What are some examples of older platforms that can't use the newer exec
> code? I don't think this is a usecase that is very common (using fairly
> outdated platforms with new cli). Maybe a solution would be that newer
> versions of the cli don't work with those old versions of platforms.
>
> In terms of app plugin, we have a transform for that very case part of the
> browserify code.
>
> https://github.com/apache/cordova-js/blob/master/tasks/lib/require-tr.js#L52-L63
> .
>
>
> Do you know the reasoning behind keeping app plugin a part of
> cordova-android repo and not breaking it out like all of our other plugins?
>
>
> On Fri, Jan 9, 2015 at 11:50 AM, Andrew Grieve <[email protected]>
> wrote:
>
> > On Fri, Jan 9, 2015 at 2:26 PM, Steven Gill <[email protected]>
> > wrote:
> >
> > > Thanks for PRs.
> > >
> > > Andrew, the browserify method builds a cordova-js for each of the
> > installed
> > > platforms (at prepare time) and copies it over into the platforms www
> > > directory (platforms/android/assets/www, etc). We shouldn't have to
> move
> > > platform specific js into platform folders because it is still
> building a
> > > unique cordova js file for each platform.
> > >
> >
> > I wouldn't want a newer version of cordova-js's exec() bridge code being
> > used with an older version of the platform. Likewise, Android has an
> "App"
> > / "CoreAndroid" plugin, that assumes it's lockstep with the .java files
> > within the platform.
> >
> >
> >
> > >
> > > On Fri, Jan 9, 2015 at 10:41 AM, Josh Soref <[email protected]>
> > wrote:
> > >
> > > > Steven Gill wrote:
> > > >
> > > > >
> > > > >
> > > >
> > >
> >
> https://github.com/cordova/apache-blog-posts/blob/master/2015-01-08-tools-
> > > > >release.md
> > > > >
> > > > > PRs welcome!
> > > >
> > > > https://github.com/cordova/apache-blog-posts/pull/28
> > > >
> > >
> >
>

Reply via email to