December 29, 2017
  • All

Help Test Ionic Native 5

Max Lynch

CEO

The next release of Ionic Native is just about ready, and we need your help testing.

Ionic Native 5 brings the project to fully framework-agnostic status, as we prepare Ionic Framework for a future where our components work in any popular framework, or without one at all. This also means that Ionic Native 5 is the nail in the coffin for ngCordova, as Ionic Native 5 will work in any situation that ngCordova did for AngularJS, along with having many more maintained plugins.

Version 5 brings a number of changes:

  • We now ship three bundles: one with Angular (5.x+) providers, ES6 modules, and a bundle (which has AngularJS support).
  • The ES6 and bundle releases feature static classes for plugins, (i.e. Camera.blah) instead of having to instantiate them
  • Ionic devs using Angular can choose between using injectables, or import and use the ES6 plugins statically

Currently, Ionic Native 5 requires Angular 5 for those choosing to use injectables/providers.

Installing in ionic-angular with Angular 5.x or greater

Run npm install --save @ionic-native/core@beta

Then, for each plugin, update to the @beta release and add ngx to the import, for example:

npm install --save @ionic-native/camera@beta

Then, import the plugin as usual:

import { Camera } from '@ionic-native/camera/ngx';

Installing in Ionic 1/AngularJS/other framework

If your project is using ES6 modules, run

npm install --save @ionic-native/core@beta

And each plugin updated as in this example:

npm install --save @ionic-native/camera@beta

Installing the bundle

The bundle can be used in any JavaScript project using any framework, or none at all.

If you’d like to use the bundle as a script include, download the bundle (minified or unminified) from the latest github release of Ionic Native 5+

Let us know what you think

Take a look at the v5 README for more info and examples on usage.

Leave a comment or file an issue if you run into any troubles!

Happy new year!


Max Lynch

CEO