react-native-mmkv icon indicating copy to clipboard operation
react-native-mmkv copied to clipboard

Propagate value change to native module side

Open pke opened this issue 1 year ago • 0 comments

More a discussion entry but discussions are not yet enabled here:

Since the value change listener are not directly supported by mmkv native module would it somehow be possible to call the react-native app delegate / MainApplication respectively with a JS emitted event?

DeviceEventEmitter.emit("mmkv/change", { name: "keyname", newValue: "newvalue", oldValue: "oldValue" })

I found no way to register an event listener on the native side, only how to create emitters.

pke avatar Sep 16 '22 20:09 pke