Creating Plugins

Creating new plugins for coraline is relatively straightforward.

You basically need to generate a dynamically loadable library (an .so file) that:

  • Exposes few standardized loader functions, one of which returns:
  • An object that implements the plugin interface

If you’re porting an existing cordova/ionic plugin to coraline, you must of course make it such that the app/user facing side respects the same API–that’s the whole point of coraline and cordova, after all.

That plugin object will be responsible for reacting to user requests and triggering the callbacks that eventually make it back into the javascript engine.

Get more info on developing plugins (including a plugin code generator) or on the plugin lifecycle.

NOTE: A method for easily wrapping existing cordova/Qt plugins is in the works.  More info will be available in the near future.