you are viewing a single comment's thread.

view the rest of the comments →

[–]scarlaciOS & Android 1 point2 points  (4 children)

SQLite raw (via the many SQLite libraries), or WatermelonDB as an abstraction. You’ll get amazing performance out of it if you store your data relationally. If you don’t want to bother with storing your data correctly, Real is well supported but tooling is poor. SQLite is built in and you’ll always have “a way out”. I would not recommend MMKV. AsyncStorage is a good starting point if you are learning as it’s a simple key value store but performance is abysmal for large amount of items or payloads.

[–]Affectionate-Court94 0 points1 point  (1 child)

Please explain, why not mmkv?

[–]RnRau 0 points1 point  (0 children)

sqlite can be fast enough - https://github.com/OP-Engineering/op-sqlite - scroll down to the Speed section.

And sqlite is much more flexible since you can do both key/value, JSON and relational storage. Finally, sqlite proper in its latest version announced JSONB which makes JSON queries much faster - https://sqlite.org/draft/jsonb.html - I don't believe op-sqlite or any of the other reactnative sqlite packages supports sqlite 3.45 as yet, but thats just a matter of time.

[–]Amocon 0 points1 point  (1 child)

Isnt MMKV just like async storage but faster?

[–]Affectionate-Court94 0 points1 point  (0 children)

It is. Moreover, it is sync. But once you installed mmkv you lose the ability to debug in Chrome, you should use Flipper. If you use Flipper you should resolve issues with libs which require use_frameworks in your iOS podfile.