-
Notifications
You must be signed in to change notification settings - Fork 862
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
Function for filtering #47
Comments
I need to think about this. Initially the concept behind redux-persist was to simplify the persistence model by allowing reducer scoped blacklist/whitelist. That said I do not want to be overly prescriptive and I can definitely envision scenarios where more selective filtering is needed. |
@Pajn I think this makes sense. what do you think about using the same api as redux-logger and having a |
+1 |
Sounds great. |
regarding filtering actions it looks like we would need to add some extra wrapper around the subscribe since by default subscribe is action unaware. If you do decide to work on this, it is best to develop against v3 branch as that is where the latest code is. |
closing due to inactivity, feel free to PR! Also note: because this would require non-trivial extension to subscribe to be action aware, I am wary to add this to the core redux-persist lib, perhaps there is a clever way to implement this as a dependent module. |
Currently one can specify a white or blacklist of actions which should be persisted. I would like to specify a function instead which is passed the action and determine whether a rehydrate should be performed or not. If you agree I can submit a PR.
The text was updated successfully, but these errors were encountered: