ammarahm-ed / react-native-mmkv-storage

An ultra fast (0.0002s read/write), small & encrypted mobile key-value storage framework for React Native written in C++ using JSI
https://rnmmkv.now.sh
MIT License
1.58k stars 109 forks source link

[Request] Support a setMultipleItems function in the API #287

Closed TristanH closed 9 months ago

TristanH commented 1 year ago

There are many usecases where bulk writes of data should be more efficient than multiple setItems calls.

Maybe the way mmkv works this isn't the case... but if it is, would love setMultipleItems and setMultipleItemsAsync methods!

As an example, react-native-async-storage supports a method like this: https://react-native-async-storage.github.io/async-storage/docs/api#multiset

ammarahm-ed commented 1 year ago

If it's added, should by async on a separate thread so it doesn't block.

ammarahm-ed commented 9 months ago

This has been added in v0.10.0

TristanH commented 9 months ago

@ammarahm-ed great news!!