We often access a local sqlite database when we developing an app. What is the counterpart in react native? Do I have to use AsyncStorage to store data without a native modu
Full feature SQLite Plugin for React Native is available here:
https://github.com/andpor/react-native-sqlite-storage
Version 2.1.0 supports both iOS and Android and the fmk has both plain JS callback and Promise based interfaces.
Embedded persistent or in memory database for react-native https://github.com/smartdemocracy/react-native-local-mongodb
It's have Performance statistics
Updated answer: there's now a fledgling SQLite wrapper available:
https://github.com/andpor/react-native-sqlite-storage
Previously:
This comment on Hacker News indicates that there's nothing available right now:
There is currently no native module for SQLite, but you can build one if you want. :-D http://facebook.github.io/react-native/docs/nativemodulesios.html
We use a key-value store for most of our client-side persistence: http://facebook.github.io/react-native/docs/asyncstorage.html
It's by Eric Vicenti who seems to work at Facebook and contribute to React Native, so pretty authoritative.
Realm React Native enables you to efficiently write your app’s model layer in a safe, persisted and fast way. Here’s what it looks like: See Realm React Native and Docs For Realm