cordova-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Andrew Grieve <agri...@chromium.org>
Subject Re: Fast edit-refresh cycles
Date Thu, 22 Nov 2012 03:42:15 GMT
On Wed, Nov 21, 2012 at 6:37 PM, Filip Maj <fil@adobe.com> wrote:

> Dude: awesome!
>
> My answers in-line:
>
> >2. Manually adding the <script> tags to include every new plugin is really
> >lame. I propose a unified file, plugins.js or similar, that's always
> >included in the index.html. Every time you add or remove a plugin, the
> >Javascript files for all the plugins are concatenated into this file.
> >There
> >are likely some problems with this approach. Inserting/removing the
> ><script> tags from the index page is also an option, though it requires
> >more clever scripts.
>
> Can you elaborate more on this? I don't understand.
>

Here's the motivating example to explain this:
- Our goal for 3.0 is to have cordova be just the bridge, and to have all
core plugins in separate repos
- Right now, when you pluginstall a plugin, you need to manually edit your
.html to add the .js of the plugin in a <script> tag.
- This will be quite annoying to have to add ~10 <script> tags, (one for
each core plugin, plus one for each non-core plugin you have)

Here's Braden's idea explained a bit more:
- Have a plugin.js file in addition to the cordova.js file
- cordova.js to have the platform's bridge & init code
- plugins.js to contain the concatenation of all plugin .js files
- plugins.js to be regenerated whenever a plugin is added / removed
- Apps will need to add both .js files to their html, but not need to add a
<script> for every plugin separately.



>
> >3. Setting the start page manually on every platform sucks. I think this
> >should be a value in config.xml that gets set on cordova build. Obviously
> >that requires 1. to be fixed, but we'll get there soon.
>
> Yes, there is config.xml prior art for this:
> http://www.w3.org/TR/widgets/#the-content-element-and-its-attributes
>
> We should file issues to add support for this.
>
> Thanks for forking + contributing to cordova-client, stoked to see more
> contributors in there! Related: once we migrate to our new git repos we
> should get a new one set up for cordova-client.
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message