I use the Native Storage example and run it in iOS simulator. I have installed the native storage with command
ionic plugin add cordova-plugin-nativestorage
But it gives Error storing item: plugin_not_installed
The code is as in the example of Ionic2 document
import { NativeStorage } from ‘ionic-native’;
ionViewWillEnter() {
NativeStorage.setItem(‘myitem’, {property: ‘value’, anotherProperty: ‘anotherValue’})
.then(
() => this.result = ‘Stored item!’,
error => this.result = ‘Error storing item:’ + error
);
}
What could be the reason? Thanks!