A React wrapper around cordova-sqlite-storage providing a Promise-based SQLite API. Version 1.1.51 offers utilities like openDB, closeDB, setData, getData, updateData, removeData, and query. Also includes SLStore for transparent data persistence: uses SQLite on Cordova and localStorage on web. Ships TypeScript types. Under active development (updated as needed). Requires cordova-sqlite-storage ^6.0.0 as a peer dependency.
npm install cordova-sqlite-reactNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Shows basic usage: openDB, insert (setData), query (getData), and closeDB with error handling.
Set isCreateDate: false in options if you don't want those columns.
Pass true as second argument to getData or parse manually.
Use stringWhere with single quotes for manual WHERE clauses, or ensure your SQLite version supports double quotes (usually yes for string comparison).
Always provide a where clause or use stringWhere to avoid accidental mass deletion.
npm install cordova-sqlite-storage
Use import { Sqlite } from 'cordova-sqlite-react'Ensure import { Sqlite } from 'cordova-sqlite-react' is at top of file.Ensure cordova.js is loaded or use SLStore (which falls back to localStorage on web).