meteorrn / meteor-react-native

Meteor client for React Native matching Meteor Spec
https://guide.meteor.com/react-native.html
Other
59 stars 31 forks source link

Cannot use RN community AsyncStorage, allow for other solutions #6

Closed PolarisWT closed 4 years ago

PolarisWT commented 4 years ago

Glad to see this package resurrected! Thank you!

React Native developers using Expo (as of v37 - most current as of this issue creation) are stuck using the depreciated React Native implementation of AsyncStorage. There is no way (without ejecting) to use the community version.

Allowing the developer to import their preferred AsyncStorage package and passing it via options in the connect(endpoint, options) method would allow Expo users to enjoy this package as well.

Another package that has done this, is Redux-Persist and can provide a good example of implementation.

I will have a PR shortly to address this. Or, if anyone has a better solution, I would be interested to hear it!

Cheers.