-
-
Notifications
You must be signed in to change notification settings - Fork 192
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
Undo / redo using immer Patch ? #124
Comments
Hey @vikasaditya Great to hear. 👍 I would try to avoid leaning on Kind of like: import undoable from 'redux-undo';
import { createStore } from 'easy-peasy';
const store = createStore(model, {
reducerEnhancer: reducer => undoable(reducer, reduxUndoConfig),
}); It looks like Hope this helps. |
Thanks for prompt reply. |
Can you take a quick look at https://codesandbox.io/s/rj5mnjz7wn ? |
My apologies @vikasaditya I looked into this a bit more and we won't be able to support redux-undo. This is because it changes the shape of your store state. :( I will have a think and if any new ideas come to me I will let you know. |
okey, will wait. |
I did have some ideas, but I need to let them sit for a while. Generally it takes me a few cycles/revisions until I come up with an API/solution that is effective. |
Not planning anything like this for now. Going to leave the problem in user-land for now unless much bigger demand comes for it. |
hi,
We are using you lib in a large project and team is loving your approach.
There is one thing that is not clear to me at least is how can we use immer Patch to implement an undo / redo ?
And if not then any pointers would be greatly appreciated, maybe something like redux undo/redo example?
Thanks
The text was updated successfully, but these errors were encountered: