You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cordova.apache.org by Michael Brooks <mi...@michaelbrooks.ca> on 2012/07/16 20:41:56 UTC
Plugin Development Guide
Hello guys,
The plugin development guide exists as issue CB-862 [1] with sub-tasks for
each plugin.
Immediate Goal:
The goal is the walk the user through developing a simple "Hello Cordova"
plugin.
In issue CB-862, I've proposed walking the user through the creation of a
"Cordova Echo" plugin that simply returns the same string that it was
called with. This shows the user the plugin's invoke cycle and condenses it
into an example that uses minimal code.
Source Code:
It would be nice if we can host these plugins somewhere. Thoughts on where?
Platform repo? Labs branch for each plugin? Common labs branch that uses
the plugin specification draft [2]?
Longer-term Goal:
Later on, we can expand this guide into a plugin development section that
is a complete reference for native constants, accepting and returning
various formats (string, number, json, array, etc).
Michael
[1] https://issues.apache.org/jira/browse/CB-862
[2] https://github.com/alunny/cordova-plugin-spec
Re: Plugin Development Guide
Posted by Filip Maj <fi...@adobe.com>.
Me likey.
On 7/16/12 1:29 PM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>+1 to the convention.
>
>Platform / Supporting Lib:
>cordova-xxx
>
>Plugin:
>cordova-plugin-xxx
>
>Demo App:
>cordova-app-xxx
>
>On Mon, Jul 16, 2012 at 1:13 PM, Brian LeRoux <b...@brian.io> wrote:
>
>> agree. also: would like to start a convention here we discussed some
>>time
>> ago.
>>
>> platforms and cordova core stuff are all named cordova-whatever-whatever
>>
>> would like to see a convention encouraged wherein plugins are called
>> cordova-plugin-whatever-whatever
>>
>> no major benefit other than symmetry which is nice to have =)
>>
>> On Mon, Jul 16, 2012 at 12:54 PM, Michael Brooks
>> <mi...@michaelbrooks.ca> wrote:
>> > My original thought is that the cordova-cli tool should be able to
>> create a
>> > plugin with a given name. The created plugin will also be the echo
>> example,
>> > since it sets up all scaffolding required to start implementing your
>>own
>> > plugin. When the echo plugin is available under it's own repository,
>>it
>> > should be easy for the CLI tool to consume this plugin.
>> >
>> > Michael
>> >
>> > On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
>> >
>> >> like it, another nice thing about that echo plugin is a baseline for
>> >> benching the bridge perf; fil should this tie into the cordova-cli
>> >> stuff?
>> >>
>> >> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
>> >> > Great stuff Mike, thanks.
>> >> >
>> >> > I think for the easy win, we host it under an "example-plugin"
>>folder
>> or
>> >> > something of the like in the platform repos this week.
>> >> >
>> >> > I can aggregate these into a labs branch and add in support for the
>> >> > cordova plugin spec, structure the code appropriately, etc.
>> >> >
>> >> > On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca>
>> wrote:
>> >> >
>> >> >>Hello guys,
>> >> >>
>> >> >>The plugin development guide exists as issue CB-862 [1] with
>>sub-tasks
>> >> for
>> >> >>each plugin.
>> >> >>
>> >> >>Immediate Goal:
>> >> >>
>> >> >>The goal is the walk the user through developing a simple "Hello
>> Cordova"
>> >> >>plugin.
>> >> >>
>> >> >>In issue CB-862, I've proposed walking the user through the
>>creation
>> of a
>> >> >>"Cordova Echo" plugin that simply returns the same string that it
>>was
>> >> >>called with. This shows the user the plugin's invoke cycle and
>> condenses
>> >> >>it
>> >> >>into an example that uses minimal code.
>> >> >>
>> >> >>Source Code:
>> >> >>
>> >> >>It would be nice if we can host these plugins somewhere. Thoughts
>>on
>> >> >>where?
>> >> >>Platform repo? Labs branch for each plugin? Common labs branch that
>> uses
>> >> >>the plugin specification draft [2]?
>> >> >>
>> >> >>Longer-term Goal:
>> >> >>
>> >> >>Later on, we can expand this guide into a plugin development
>>section
>> that
>> >> >>is a complete reference for native constants, accepting and
>>returning
>> >> >>various formats (string, number, json, array, etc).
>> >> >>
>> >> >>Michael
>> >> >>
>> >> >>[1] https://issues.apache.org/jira/browse/CB-862
>> >> >>[2] https://github.com/alunny/cordova-plugin-spec
>> >> >
>> >>
>>
Re: Plugin Development Guide
Posted by Michael Brooks <mi...@michaelbrooks.ca>.
+1 to the convention.
Platform / Supporting Lib:
cordova-xxx
Plugin:
cordova-plugin-xxx
Demo App:
cordova-app-xxx
On Mon, Jul 16, 2012 at 1:13 PM, Brian LeRoux <b...@brian.io> wrote:
> agree. also: would like to start a convention here we discussed some time
> ago.
>
> platforms and cordova core stuff are all named cordova-whatever-whatever
>
> would like to see a convention encouraged wherein plugins are called
> cordova-plugin-whatever-whatever
>
> no major benefit other than symmetry which is nice to have =)
>
> On Mon, Jul 16, 2012 at 12:54 PM, Michael Brooks
> <mi...@michaelbrooks.ca> wrote:
> > My original thought is that the cordova-cli tool should be able to
> create a
> > plugin with a given name. The created plugin will also be the echo
> example,
> > since it sets up all scaffolding required to start implementing your own
> > plugin. When the echo plugin is available under it's own repository, it
> > should be easy for the CLI tool to consume this plugin.
> >
> > Michael
> >
> > On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
> >
> >> like it, another nice thing about that echo plugin is a baseline for
> >> benching the bridge perf; fil should this tie into the cordova-cli
> >> stuff?
> >>
> >> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
> >> > Great stuff Mike, thanks.
> >> >
> >> > I think for the easy win, we host it under an "example-plugin" folder
> or
> >> > something of the like in the platform repos this week.
> >> >
> >> > I can aggregate these into a labs branch and add in support for the
> >> > cordova plugin spec, structure the code appropriately, etc.
> >> >
> >> > On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca>
> wrote:
> >> >
> >> >>Hello guys,
> >> >>
> >> >>The plugin development guide exists as issue CB-862 [1] with sub-tasks
> >> for
> >> >>each plugin.
> >> >>
> >> >>Immediate Goal:
> >> >>
> >> >>The goal is the walk the user through developing a simple "Hello
> Cordova"
> >> >>plugin.
> >> >>
> >> >>In issue CB-862, I've proposed walking the user through the creation
> of a
> >> >>"Cordova Echo" plugin that simply returns the same string that it was
> >> >>called with. This shows the user the plugin's invoke cycle and
> condenses
> >> >>it
> >> >>into an example that uses minimal code.
> >> >>
> >> >>Source Code:
> >> >>
> >> >>It would be nice if we can host these plugins somewhere. Thoughts on
> >> >>where?
> >> >>Platform repo? Labs branch for each plugin? Common labs branch that
> uses
> >> >>the plugin specification draft [2]?
> >> >>
> >> >>Longer-term Goal:
> >> >>
> >> >>Later on, we can expand this guide into a plugin development section
> that
> >> >>is a complete reference for native constants, accepting and returning
> >> >>various formats (string, number, json, array, etc).
> >> >>
> >> >>Michael
> >> >>
> >> >>[1] https://issues.apache.org/jira/browse/CB-862
> >> >>[2] https://github.com/alunny/cordova-plugin-spec
> >> >
> >>
>
Re: Plugin Development Guide
Posted by Brian LeRoux <b...@brian.io>.
agree. also: would like to start a convention here we discussed some time ago.
platforms and cordova core stuff are all named cordova-whatever-whatever
would like to see a convention encouraged wherein plugins are called
cordova-plugin-whatever-whatever
no major benefit other than symmetry which is nice to have =)
On Mon, Jul 16, 2012 at 12:54 PM, Michael Brooks
<mi...@michaelbrooks.ca> wrote:
> My original thought is that the cordova-cli tool should be able to create a
> plugin with a given name. The created plugin will also be the echo example,
> since it sets up all scaffolding required to start implementing your own
> plugin. When the echo plugin is available under it's own repository, it
> should be easy for the CLI tool to consume this plugin.
>
> Michael
>
> On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
>
>> like it, another nice thing about that echo plugin is a baseline for
>> benching the bridge perf; fil should this tie into the cordova-cli
>> stuff?
>>
>> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
>> > Great stuff Mike, thanks.
>> >
>> > I think for the easy win, we host it under an "example-plugin" folder or
>> > something of the like in the platform repos this week.
>> >
>> > I can aggregate these into a labs branch and add in support for the
>> > cordova plugin spec, structure the code appropriately, etc.
>> >
>> > On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>> >
>> >>Hello guys,
>> >>
>> >>The plugin development guide exists as issue CB-862 [1] with sub-tasks
>> for
>> >>each plugin.
>> >>
>> >>Immediate Goal:
>> >>
>> >>The goal is the walk the user through developing a simple "Hello Cordova"
>> >>plugin.
>> >>
>> >>In issue CB-862, I've proposed walking the user through the creation of a
>> >>"Cordova Echo" plugin that simply returns the same string that it was
>> >>called with. This shows the user the plugin's invoke cycle and condenses
>> >>it
>> >>into an example that uses minimal code.
>> >>
>> >>Source Code:
>> >>
>> >>It would be nice if we can host these plugins somewhere. Thoughts on
>> >>where?
>> >>Platform repo? Labs branch for each plugin? Common labs branch that uses
>> >>the plugin specification draft [2]?
>> >>
>> >>Longer-term Goal:
>> >>
>> >>Later on, we can expand this guide into a plugin development section that
>> >>is a complete reference for native constants, accepting and returning
>> >>various formats (string, number, json, array, etc).
>> >>
>> >>Michael
>> >>
>> >>[1] https://issues.apache.org/jira/browse/CB-862
>> >>[2] https://github.com/alunny/cordova-plugin-spec
>> >
>>
Re: Plugin Development Guide
Posted by Filip Maj <fi...@adobe.com>.
... Why?
On 7/17/12 1:44 AM, "Tommy Williams" <to...@devgeeks.org> wrote:
>+1
>
>> p.s
>> REALLY want good docs on plugins for 2.0 on release - seen the changes
>>to
>> Cordova2.0 and really freaked out right now... :p
>>
>
Re: Plugin Development Guide
Posted by Tommy Williams <to...@devgeeks.org>.
+1
> p.s
> REALLY want good docs on plugins for 2.0 on release - seen the changes to
> Cordova2.0 and really freaked out right now... :p
>
Re: Plugin Development Guide
Posted by Ally Ogilvie <ao...@wizcorp.jp>.
@Brian
> would like to see a convention encouraged wherein plugins are called
cordova-plugin-whatever-whatever
^ With you on that...
:)
https://github.com/Wizcorp/phonegap-plugin-apsalar
https://github.com/Wizcorp/phonegap-plugin-localNotifications
https://github.com/Wizcorp/phonegap-plugin-wizSpinner
https://github.com/Wizcorp/phonegap-plugin-wizAnalytics
https://github.com/Wizcorp/phonegap-plugin-wizUtils
https://github.com/Wizcorp/phonegap-plugin-wizDevTools
https://github.com/Wizcorp/phonegap-plugin-wizAssets
https://github.com/Wizcorp/phonegap-plugin-wizViewManager
https://github.com/Wizcorp/phonegap-plugin-wizNavi
https://github.com/Wizcorp/phonegap-plugin-wizStatbar
p.s
REALLY want good docs on plugins for 2.0 on release - seen the changes to
Cordova2.0 and really freaked out right now... :p
On Tue, Jul 17, 2012 at 7:16 AM, Filip Maj <fi...@adobe.com> wrote:
> Following the convention of the core APIS, the module id should be:
>
> cordova/plugin/foo
>
> On 7/16/12 3:10 PM, "Don Coleman" <do...@gmail.com> wrote:
>
> >I like the idea of an echo plugin. I might switch my phonegap day
> >example from cordova-plugin-helloworld to cordova-plugin-echo
> >
> >Any suggested naming conventions for the JavaScript module?
> >
> >cordova.define("foo", function() {});
> >
> >foo
> >/plugin/foo
> >/cordova/plugin/foo
> >
> >On Mon, Jul 16, 2012 at 5:48 PM, Tommy-Carlos Williams
> ><to...@devgeeks.org> wrote:
> >> This is all sounding really good. Looking forward to a better day for
> >>plugin devs.
> >>
> >> Congrats on all your hard work.
> >>
> >>
> >>
> >> On 17/07/2012, at 5:54, Michael Brooks <mi...@michaelbrooks.ca>
> wrote:
> >>
> >>> My original thought is that the cordova-cli tool should be able to
> >>>create a
> >>> plugin with a given name. The created plugin will also be the echo
> >>>example,
> >>> since it sets up all scaffolding required to start implementing your
> >>>own
> >>> plugin. When the echo plugin is available under it's own repository, it
> >>> should be easy for the CLI tool to consume this plugin.
> >>>
> >>> Michael
> >>>
> >>> On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
> >>>
> >>>> like it, another nice thing about that echo plugin is a baseline for
> >>>> benching the bridge perf; fil should this tie into the cordova-cli
> >>>> stuff?
> >>>>
> >>>> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
> >>>>> Great stuff Mike, thanks.
> >>>>>
> >>>>> I think for the easy win, we host it under an "example-plugin"
> >>>>>folder or
> >>>>> something of the like in the platform repos this week.
> >>>>>
> >>>>> I can aggregate these into a labs branch and add in support for the
> >>>>> cordova plugin spec, structure the code appropriately, etc.
> >>>>>
> >>>>> On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca>
> >>>>>wrote:
> >>>>>
> >>>>>> Hello guys,
> >>>>>>
> >>>>>> The plugin development guide exists as issue CB-862 [1] with
> >>>>>>sub-tasks
> >>>> for
> >>>>>> each plugin.
> >>>>>>
> >>>>>> Immediate Goal:
> >>>>>>
> >>>>>> The goal is the walk the user through developing a simple "Hello
> >>>>>>Cordova"
> >>>>>> plugin.
> >>>>>>
> >>>>>> In issue CB-862, I've proposed walking the user through the
> >>>>>>creation of a
> >>>>>> "Cordova Echo" plugin that simply returns the same string that it
> >>>>>>was
> >>>>>> called with. This shows the user the plugin's invoke cycle and
> >>>>>>condenses
> >>>>>> it
> >>>>>> into an example that uses minimal code.
> >>>>>>
> >>>>>> Source Code:
> >>>>>>
> >>>>>> It would be nice if we can host these plugins somewhere. Thoughts on
> >>>>>> where?
> >>>>>> Platform repo? Labs branch for each plugin? Common labs branch that
> >>>>>>uses
> >>>>>> the plugin specification draft [2]?
> >>>>>>
> >>>>>> Longer-term Goal:
> >>>>>>
> >>>>>> Later on, we can expand this guide into a plugin development
> >>>>>>section that
> >>>>>> is a complete reference for native constants, accepting and
> >>>>>>returning
> >>>>>> various formats (string, number, json, array, etc).
> >>>>>>
> >>>>>> Michael
> >>>>>>
> >>>>>> [1] https://issues.apache.org/jira/browse/CB-862
> >>>>>> [2] https://github.com/alunny/cordova-plugin-spec
> >>>>>
> >>>>
>
>
--
Ally Ogilvie
Lead Developer [ iOS, Android ]
Mobile Devices
[image:
http://www.wizcorp.jp/wp-content/themes/business-lite/images/all/wizcorp-logo.png]
3-10-14-6F Higashi Nihombashi,
Chuo-ku
103-0004, Tokyo
Tel: (+81)3-4550-1448
E-mail: aogilvie@wizcorp.jp
Re: Plugin Development Guide
Posted by Filip Maj <fi...@adobe.com>.
Following the convention of the core APIS, the module id should be:
cordova/plugin/foo
On 7/16/12 3:10 PM, "Don Coleman" <do...@gmail.com> wrote:
>I like the idea of an echo plugin. I might switch my phonegap day
>example from cordova-plugin-helloworld to cordova-plugin-echo
>
>Any suggested naming conventions for the JavaScript module?
>
>cordova.define("foo", function() {});
>
>foo
>/plugin/foo
>/cordova/plugin/foo
>
>On Mon, Jul 16, 2012 at 5:48 PM, Tommy-Carlos Williams
><to...@devgeeks.org> wrote:
>> This is all sounding really good. Looking forward to a better day for
>>plugin devs.
>>
>> Congrats on all your hard work.
>>
>>
>>
>> On 17/07/2012, at 5:54, Michael Brooks <mi...@michaelbrooks.ca> wrote:
>>
>>> My original thought is that the cordova-cli tool should be able to
>>>create a
>>> plugin with a given name. The created plugin will also be the echo
>>>example,
>>> since it sets up all scaffolding required to start implementing your
>>>own
>>> plugin. When the echo plugin is available under it's own repository, it
>>> should be easy for the CLI tool to consume this plugin.
>>>
>>> Michael
>>>
>>> On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
>>>
>>>> like it, another nice thing about that echo plugin is a baseline for
>>>> benching the bridge perf; fil should this tie into the cordova-cli
>>>> stuff?
>>>>
>>>> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
>>>>> Great stuff Mike, thanks.
>>>>>
>>>>> I think for the easy win, we host it under an "example-plugin"
>>>>>folder or
>>>>> something of the like in the platform repos this week.
>>>>>
>>>>> I can aggregate these into a labs branch and add in support for the
>>>>> cordova plugin spec, structure the code appropriately, etc.
>>>>>
>>>>> On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca>
>>>>>wrote:
>>>>>
>>>>>> Hello guys,
>>>>>>
>>>>>> The plugin development guide exists as issue CB-862 [1] with
>>>>>>sub-tasks
>>>> for
>>>>>> each plugin.
>>>>>>
>>>>>> Immediate Goal:
>>>>>>
>>>>>> The goal is the walk the user through developing a simple "Hello
>>>>>>Cordova"
>>>>>> plugin.
>>>>>>
>>>>>> In issue CB-862, I've proposed walking the user through the
>>>>>>creation of a
>>>>>> "Cordova Echo" plugin that simply returns the same string that it
>>>>>>was
>>>>>> called with. This shows the user the plugin's invoke cycle and
>>>>>>condenses
>>>>>> it
>>>>>> into an example that uses minimal code.
>>>>>>
>>>>>> Source Code:
>>>>>>
>>>>>> It would be nice if we can host these plugins somewhere. Thoughts on
>>>>>> where?
>>>>>> Platform repo? Labs branch for each plugin? Common labs branch that
>>>>>>uses
>>>>>> the plugin specification draft [2]?
>>>>>>
>>>>>> Longer-term Goal:
>>>>>>
>>>>>> Later on, we can expand this guide into a plugin development
>>>>>>section that
>>>>>> is a complete reference for native constants, accepting and
>>>>>>returning
>>>>>> various formats (string, number, json, array, etc).
>>>>>>
>>>>>> Michael
>>>>>>
>>>>>> [1] https://issues.apache.org/jira/browse/CB-862
>>>>>> [2] https://github.com/alunny/cordova-plugin-spec
>>>>>
>>>>
Re: Plugin Development Guide
Posted by Don Coleman <do...@gmail.com>.
I like the idea of an echo plugin. I might switch my phonegap day
example from cordova-plugin-helloworld to cordova-plugin-echo
Any suggested naming conventions for the JavaScript module?
cordova.define("foo", function() {});
foo
/plugin/foo
/cordova/plugin/foo
On Mon, Jul 16, 2012 at 5:48 PM, Tommy-Carlos Williams
<to...@devgeeks.org> wrote:
> This is all sounding really good. Looking forward to a better day for plugin devs.
>
> Congrats on all your hard work.
>
>
>
> On 17/07/2012, at 5:54, Michael Brooks <mi...@michaelbrooks.ca> wrote:
>
>> My original thought is that the cordova-cli tool should be able to create a
>> plugin with a given name. The created plugin will also be the echo example,
>> since it sets up all scaffolding required to start implementing your own
>> plugin. When the echo plugin is available under it's own repository, it
>> should be easy for the CLI tool to consume this plugin.
>>
>> Michael
>>
>> On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
>>
>>> like it, another nice thing about that echo plugin is a baseline for
>>> benching the bridge perf; fil should this tie into the cordova-cli
>>> stuff?
>>>
>>> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
>>>> Great stuff Mike, thanks.
>>>>
>>>> I think for the easy win, we host it under an "example-plugin" folder or
>>>> something of the like in the platform repos this week.
>>>>
>>>> I can aggregate these into a labs branch and add in support for the
>>>> cordova plugin spec, structure the code appropriately, etc.
>>>>
>>>> On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>>>>
>>>>> Hello guys,
>>>>>
>>>>> The plugin development guide exists as issue CB-862 [1] with sub-tasks
>>> for
>>>>> each plugin.
>>>>>
>>>>> Immediate Goal:
>>>>>
>>>>> The goal is the walk the user through developing a simple "Hello Cordova"
>>>>> plugin.
>>>>>
>>>>> In issue CB-862, I've proposed walking the user through the creation of a
>>>>> "Cordova Echo" plugin that simply returns the same string that it was
>>>>> called with. This shows the user the plugin's invoke cycle and condenses
>>>>> it
>>>>> into an example that uses minimal code.
>>>>>
>>>>> Source Code:
>>>>>
>>>>> It would be nice if we can host these plugins somewhere. Thoughts on
>>>>> where?
>>>>> Platform repo? Labs branch for each plugin? Common labs branch that uses
>>>>> the plugin specification draft [2]?
>>>>>
>>>>> Longer-term Goal:
>>>>>
>>>>> Later on, we can expand this guide into a plugin development section that
>>>>> is a complete reference for native constants, accepting and returning
>>>>> various formats (string, number, json, array, etc).
>>>>>
>>>>> Michael
>>>>>
>>>>> [1] https://issues.apache.org/jira/browse/CB-862
>>>>> [2] https://github.com/alunny/cordova-plugin-spec
>>>>
>>>
Re: Plugin Development Guide
Posted by Tommy-Carlos Williams <to...@devgeeks.org>.
This is all sounding really good. Looking forward to a better day for plugin devs.
Congrats on all your hard work.
On 17/07/2012, at 5:54, Michael Brooks <mi...@michaelbrooks.ca> wrote:
> My original thought is that the cordova-cli tool should be able to create a
> plugin with a given name. The created plugin will also be the echo example,
> since it sets up all scaffolding required to start implementing your own
> plugin. When the echo plugin is available under it's own repository, it
> should be easy for the CLI tool to consume this plugin.
>
> Michael
>
> On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
>
>> like it, another nice thing about that echo plugin is a baseline for
>> benching the bridge perf; fil should this tie into the cordova-cli
>> stuff?
>>
>> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
>>> Great stuff Mike, thanks.
>>>
>>> I think for the easy win, we host it under an "example-plugin" folder or
>>> something of the like in the platform repos this week.
>>>
>>> I can aggregate these into a labs branch and add in support for the
>>> cordova plugin spec, structure the code appropriately, etc.
>>>
>>> On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>>>
>>>> Hello guys,
>>>>
>>>> The plugin development guide exists as issue CB-862 [1] with sub-tasks
>> for
>>>> each plugin.
>>>>
>>>> Immediate Goal:
>>>>
>>>> The goal is the walk the user through developing a simple "Hello Cordova"
>>>> plugin.
>>>>
>>>> In issue CB-862, I've proposed walking the user through the creation of a
>>>> "Cordova Echo" plugin that simply returns the same string that it was
>>>> called with. This shows the user the plugin's invoke cycle and condenses
>>>> it
>>>> into an example that uses minimal code.
>>>>
>>>> Source Code:
>>>>
>>>> It would be nice if we can host these plugins somewhere. Thoughts on
>>>> where?
>>>> Platform repo? Labs branch for each plugin? Common labs branch that uses
>>>> the plugin specification draft [2]?
>>>>
>>>> Longer-term Goal:
>>>>
>>>> Later on, we can expand this guide into a plugin development section that
>>>> is a complete reference for native constants, accepting and returning
>>>> various formats (string, number, json, array, etc).
>>>>
>>>> Michael
>>>>
>>>> [1] https://issues.apache.org/jira/browse/CB-862
>>>> [2] https://github.com/alunny/cordova-plugin-spec
>>>
>>
Re: Plugin Development Guide
Posted by Michael Brooks <mi...@michaelbrooks.ca>.
My original thought is that the cordova-cli tool should be able to create a
plugin with a given name. The created plugin will also be the echo example,
since it sets up all scaffolding required to start implementing your own
plugin. When the echo plugin is available under it's own repository, it
should be easy for the CLI tool to consume this plugin.
Michael
On Mon, Jul 16, 2012 at 12:46 PM, Brian LeRoux <b...@brian.io> wrote:
> like it, another nice thing about that echo plugin is a baseline for
> benching the bridge perf; fil should this tie into the cordova-cli
> stuff?
>
> On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
> > Great stuff Mike, thanks.
> >
> > I think for the easy win, we host it under an "example-plugin" folder or
> > something of the like in the platform repos this week.
> >
> > I can aggregate these into a labs branch and add in support for the
> > cordova plugin spec, structure the code appropriately, etc.
> >
> > On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
> >
> >>Hello guys,
> >>
> >>The plugin development guide exists as issue CB-862 [1] with sub-tasks
> for
> >>each plugin.
> >>
> >>Immediate Goal:
> >>
> >>The goal is the walk the user through developing a simple "Hello Cordova"
> >>plugin.
> >>
> >>In issue CB-862, I've proposed walking the user through the creation of a
> >>"Cordova Echo" plugin that simply returns the same string that it was
> >>called with. This shows the user the plugin's invoke cycle and condenses
> >>it
> >>into an example that uses minimal code.
> >>
> >>Source Code:
> >>
> >>It would be nice if we can host these plugins somewhere. Thoughts on
> >>where?
> >>Platform repo? Labs branch for each plugin? Common labs branch that uses
> >>the plugin specification draft [2]?
> >>
> >>Longer-term Goal:
> >>
> >>Later on, we can expand this guide into a plugin development section that
> >>is a complete reference for native constants, accepting and returning
> >>various formats (string, number, json, array, etc).
> >>
> >>Michael
> >>
> >>[1] https://issues.apache.org/jira/browse/CB-862
> >>[2] https://github.com/alunny/cordova-plugin-spec
> >
>
Re: Plugin Development Guide
Posted by Brian LeRoux <b...@brian.io>.
like it, another nice thing about that echo plugin is a baseline for
benching the bridge perf; fil should this tie into the cordova-cli
stuff?
On Mon, Jul 16, 2012 at 12:13 PM, Filip Maj <fi...@adobe.com> wrote:
> Great stuff Mike, thanks.
>
> I think for the easy win, we host it under an "example-plugin" folder or
> something of the like in the platform repos this week.
>
> I can aggregate these into a labs branch and add in support for the
> cordova plugin spec, structure the code appropriately, etc.
>
> On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>
>>Hello guys,
>>
>>The plugin development guide exists as issue CB-862 [1] with sub-tasks for
>>each plugin.
>>
>>Immediate Goal:
>>
>>The goal is the walk the user through developing a simple "Hello Cordova"
>>plugin.
>>
>>In issue CB-862, I've proposed walking the user through the creation of a
>>"Cordova Echo" plugin that simply returns the same string that it was
>>called with. This shows the user the plugin's invoke cycle and condenses
>>it
>>into an example that uses minimal code.
>>
>>Source Code:
>>
>>It would be nice if we can host these plugins somewhere. Thoughts on
>>where?
>>Platform repo? Labs branch for each plugin? Common labs branch that uses
>>the plugin specification draft [2]?
>>
>>Longer-term Goal:
>>
>>Later on, we can expand this guide into a plugin development section that
>>is a complete reference for native constants, accepting and returning
>>various formats (string, number, json, array, etc).
>>
>>Michael
>>
>>[1] https://issues.apache.org/jira/browse/CB-862
>>[2] https://github.com/alunny/cordova-plugin-spec
>
Re: Plugin Development Guide
Posted by Filip Maj <fi...@adobe.com>.
Great stuff Mike, thanks.
I think for the easy win, we host it under an "example-plugin" folder or
something of the like in the platform repos this week.
I can aggregate these into a labs branch and add in support for the
cordova plugin spec, structure the code appropriately, etc.
On 7/16/12 11:41 AM, "Michael Brooks" <mi...@michaelbrooks.ca> wrote:
>Hello guys,
>
>The plugin development guide exists as issue CB-862 [1] with sub-tasks for
>each plugin.
>
>Immediate Goal:
>
>The goal is the walk the user through developing a simple "Hello Cordova"
>plugin.
>
>In issue CB-862, I've proposed walking the user through the creation of a
>"Cordova Echo" plugin that simply returns the same string that it was
>called with. This shows the user the plugin's invoke cycle and condenses
>it
>into an example that uses minimal code.
>
>Source Code:
>
>It would be nice if we can host these plugins somewhere. Thoughts on
>where?
>Platform repo? Labs branch for each plugin? Common labs branch that uses
>the plugin specification draft [2]?
>
>Longer-term Goal:
>
>Later on, we can expand this guide into a plugin development section that
>is a complete reference for native constants, accepting and returning
>various formats (string, number, json, array, etc).
>
>Michael
>
>[1] https://issues.apache.org/jira/browse/CB-862
>[2] https://github.com/alunny/cordova-plugin-spec