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

useReducer example not working with latest version #181

Open
CarlMungazi opened this issue Sep 15, 2020 · 3 comments
Open

useReducer example not working with latest version #181

CarlMungazi opened this issue Sep 15, 2020 · 3 comments

Comments

@CarlMungazi
Copy link
Contributor

This example does not seem to be working with the following package versions:

    "react": "16.13.1",
    "react-dom": "16.13.1",
    "react-scripts": "3.2.0",
    "redux-leaves": "^2.0.0"

I was trying to follow this example and I was getting the following error:

Screenshot 2020-09-16 at 00 50 10

I thought I was doing something wrong but when I updated the example to match my versions, the same error appeared. I don't understand this lib enough to know what the issue could be, so any insight would be useful!

@arezki1990
Copy link

same thing for me , did you resolve the issue ?

@CarlMungazi
Copy link
Contributor Author

I bumped my version down to 0.7.4 and used that instead. It's a short-term fix until @richardcrng is able to shed more light.

@richardcrng
Copy link
Owner

Thanks for using and flagging, @CarlMungazi and @arezki1990!

I'm in the process of deprecating Redux-Leaves in favour of Riduce (also created by me) - it's essentially the same library (shared API and a common git history), but with significant refactoring for stronger TypeScript support and a new name to de-emphasise Redux (since it should be usable with useReducer).

I haven't investigated why this useReducer example didn't work with the latest version of Redux-Leaves, but it works for me with Riduce (sandbox here).

So, as a fix for now, can you swap out redux-leaves for riduce?

(At some point, I might patch Redux-Leaves, but I don't intend to support it long-term)

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

3 participants