incubator-callback-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurent Hasson <lhas...@rim.com>
Subject RE: Unified phonegap javascript layer incorperating modules / plugins
Date Mon, 21 Nov 2011 01:38:00 GMT
Things as ambitious as PhoneGap always grow in complexity faster and bigger than people think.
I have been in way too many projects in the past where "anything goes" was the order of the
day in terms of macro structure, and then it became deeply regretted quickly. I for one don't
see a downside to using something like AMD. And if we do want to get into a much more "micro-kernel"
type approach for PhoneGap as a platform, then we'll need something.

So I would put the question differently: are people so offended by the idea of something AMD-like?
What's the downside? Verbosity? Overhead? Really? :) It enables tooling, dependency management,
code structuring, plugins etc... I don't see the downside.


Thank you
------------------------------------------------
- LDH (Laurent Hasson)                         -
- Technical Director, BlackBerry Web Platform  -
- Research In Motion                           -
- Email: lhasson@rim.com                       -
- Mobile: 646-460-7066                         -
------------------------------------------------
"Ha ha ha... He doesn't know how to use the three seashells!" - Erwin


-----Original Message-----
From: brian.leroux@gmail.com [mailto:brian.leroux@gmail.com] On Behalf Of Brian LeRoux
Sent: Sunday, November 20, 2011 3:25 PM
To: callback-dev@incubator.apache.org
Subject: Re: Unified phonegap javascript layer incorperating modules / plugins

Would like to draw attention back to the primary goal here: a single
file phonegap.js that works on all the target platforms:

- ios
- android
- blackberry
- wp7
- bada
- qt
- browser <--- never been an explicit goal, but seems consensus here
is that it should be given its a common practice during app dev

Right now our module system is classic js: we have no module loader.
=P We just concat our JS, always have, and leave the loading of that
file as an exercise for the app developer using phonegap (and it
should stay that way).

Our secondary goal w/ this effort was to determine how we could move
code out of the phonegap core and into atomic plugins. With that mind,
a module system is could make things whole lot nicer.

Do have to use a module system when we 'pluginize'? No.

Here's the big question: *should* authors of plugins be forced into a
module system? I'm thinking the answer here would be no too ---- but
I'd love to hear everyones thoughts on that.


On Sat, Nov 19, 2011 at 12:42 PM, Patrick Mueller <pmuellr@gmail.com> wrote:
> On Sat, Nov 19, 2011 at 14:21, Andrew Lunny <alunny@gmail.com> wrote:
>> For PhoneGap.js, we're dealing with a finite number of modules - around
>> twenty I'd guess, plus one for each plugin. Typically, each module only
>> depends on phonegap/base - it's very unlikely that, say, the Camera API
>> would depend on the Accelerometer, although there may be cases of cross
>> dependencies.
>
> I take it you aren't including phonegap-plugins in that list (of 20).
> Shouldn't they be?

---------------------------------------------------------------------
This transmission (including any attachments) may contain confidential information, privileged
material (including material protected by the solicitor-client or other applicable privileges),
or constitute non-public information. Any use of this information by anyone other than the
intended recipient is prohibited. If you have received this transmission in error, please
immediately reply to the sender and delete this information from your system. Use, dissemination,
distribution, or reproduction of this transmission by unintended recipients is not authorized
and may be unlawful.

Mime
View raw message