I am currently creating a React Native app which will require the user to be able to store data offline and then once only it will sync to the database. I have heard of PouchDB but don't quite understand how to implement it so advice on this might be a solution.
I am unsure which services to use due this being my first time creating a complete React Native app. I have experience using React JS, Express and Sequelize however I don't think I can use Sequelize with a React Native App.
I would like to use either NoSql or a MySQL database, however, I am open to either.
Any advice on what services to yous, languages, guides, videos would be great as I've been stuck on this for a while.
I understand that this question was asked a year ago but I found this question as I was researching an offline database solution for my own app.
One response here recommends Firebase which fits the criteria of your question perfectly but I would use it with caution. Firebase is really great for online storage and has an offline storage feature, but is not meant as a long-term offline storage solution. I've only added this caution since you said you said "once only it will sync to the database" See a couple of resources I've found on Firebase:
The offline database solution that I'll be using is MMKV, an offline storage library developed by WeChat. I found it while looking through this list of offline storage solutions while looking at AsyncStorage (Now Depreciated).
Hopefully, this response will help others like me decide what storage solution to use as well! Edit: This library doesn't work with expo.
You can use Cloud Firestore which is part of Firebase. It's a NoSQL, offline-first database that works as you are describing and it's pretty easy to use with React Native.
Docs: https://rnfirebase.io/firestore/usage
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With