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

Chore: get rid of redux-optimist #4174

Open
erezrokah opened this issue Aug 18, 2020 · 2 comments · May be fixed by #4289
Open

Chore: get rid of redux-optimist #4174

erezrokah opened this issue Aug 18, 2020 · 2 comments · May be fixed by #4289

Comments

@erezrokah
Copy link
Collaborator

@erezrokah erezrokah commented Aug 18, 2020

We use redux-optimist only for the editorial workflow which is inconsistent with the rest of the codebase, and makes the code more complicated.
Also, that package is no longer maintained.

We should remove it as unless we can think of a major benefit it produces.

@KancerEzeroglu
Copy link
Contributor

@KancerEzeroglu KancerEzeroglu commented Sep 2, 2020

I want to work on that.

  • first I need to understand the code base and how reducers work.
  • I will try to run the code and debug locally to get more context. Any advice or direction is welcome 😄
@erezrokah
Copy link
Collaborator Author

@erezrokah erezrokah commented Sep 2, 2020

You've been doing great work so far, so not much I can add.

Just the general concept of redux-optimist:
First update the redux state assuming the operation succeeded. If the operation failed, revert the state, otherwise don't do anything.

I think the idea was to make the UI respond fast when doing backend related operations assuming most of them succeed anyway.

@KancerEzeroglu KancerEzeroglu linked a pull request that will close this issue Sep 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

2 participants
You can’t perform that action at this time.