-
-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for objects? #2
Comments
Hmm, on iOS there is support for storing What do you think the return type should be? I'm thinking
|
I'll see what's possible in #7 |
A way to do it is already explain on documentation : const user = {
username: 'Marc',
age: 21
}
storage.set('user', JSON.stringify(user))
const jsonUser = storage.getString('user') // { 'username': 'Marc', 'age': 21 }
const userObject = JSON.parse(jsonUser) May this Issues should be closed ? |
Yeah I think closing this issue makes sense. |
Feature request:
I see references to things like
convertObjCObjectToJSIValue
and the reverse but mmkv.mm doesn't seem to be exposing this functionality.Would it be possible to get native object/dict support so one could avoid using
JSON.stringify()
(and rely on the native counter-part)? Or have you found that it's more trouble than it's worth?The text was updated successfully, but these errors were encountered: