Reputation: 141
I'm developing a React Native app which will easily exceed the 6mb limit. According to this, I should be able to use the method setMaximumSize, however I'm not sure of where or how I should invoke it in my project.
A practical example would be welcome.
EDIT: For anyone who needs this in the future here's how you do it:
// MainApplication.getPackages()
long size = 50L * 1024L * 1024L; // 50 MB
com.facebook.react.modules.storage.ReactDatabaseSupplier.getInstance(getApplicationContext()).setMaximumSize(size);
Upvotes: 4
Views: 2736
Reputation: 6116
Try the new way as mentioned in the documentation :
Add a AsyncStorage_db_size_in_MB
property to your android/gradle.properties
:
AsyncStorage_db_size_in_MB=10
Now you can define the new size in MB. In this example, the new limit is 10 MB.
Upvotes: 2