Skip to content
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

Ability to define the shared preferences namespace #1

Open
atticoos opened this issue Dec 8, 2015 · 2 comments
Open

Ability to define the shared preferences namespace #1

atticoos opened this issue Dec 8, 2015 · 2 comments

Comments

@atticoos
Copy link
Contributor

atticoos commented Dec 8, 2015

Temporarily hardcoded in at https://github.com/robinpowered/react-native-android-shared-preferences/blob/develop/src/main/java/com/robinpowered/react/SharedPreferencesModule.java#L19, this should be assignable in the JS context. Currently hardcoded to prevent BC in Rooms, but will be opened up to a custom assignment.

@zweihan
Copy link

zweihan commented Dec 21, 2015

For now, I modified the code to pass it as a variable from MainActivity.java when adding the package.

.addPackage(new SharedPreferencesPackage(this, "customPackageName")

This seems most straightforward for now. What are you planning for this feature?

@atticoos
Copy link
Contributor Author

We were considering two approaches -- the one you describe and the ability to do this from the JS side to allow for more than one name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants