localforage-cordova-sq-lite-driver-ts
TypeScript icon, indicating that this package has built-in type declarations

1.0.6 • Public • Published

localforage-cordovaq-sq-lite-driver-ts

npm version npm bundle size

SQLite driver for Cordova or Capacitor apps using localForage.

It's heavily inspired by localForage-cordovaSQLiteDriver which isn't actively maintained.

Setup with ionic

Install all required packages:

npm i @ionic/storage-angular localforage-cordova-sq-lite-driver-ts cordova-sqlite-storage

Next have to define the driverOrder for the IonicStorageModule:

import { IonicStorageModule } from '@ionic/storage-angular';
import { CordovaSQLiteDriver } from 'localforage-cordova-sq-lite-driver-ts';

@NgModule({
    ...
    imports: [
        ...
        IonicStorageModule.forRoot({
            driverOrder: [
                CordovaSQLiteDriver._driver,
                Drivers.IndexedDB,
                Drivers.LocalStorage,
            ],
        }),
        ...
    ]
})

Authors

Package Sidebar

Install

npm i localforage-cordova-sq-lite-driver-ts

Weekly Downloads

59

Version

1.0.6

License

MIT

Unpacked Size

12.7 kB

Total Files

12

Last publish

Collaborators

  • nico.lueg