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

Issue: Incorrect Usage of 'redux-thunk' Module #22

Open
crazycodescat opened this issue Feb 1, 2024 · 0 comments
Open

Issue: Incorrect Usage of 'redux-thunk' Module #22

crazycodescat opened this issue Feb 1, 2024 · 0 comments

Comments

@crazycodescat
Copy link

**Issue: Incorrect Usage of 'redux-thunk' Module

Description:
When attempting to apply middleware in the Redux store configuration, an error is encountered due to incorrect usage of the 'redux-thunk' module. The code attempts to import the 'redux-thunk' middleware and apply it using the 'applyMiddleware' function. However, the error message indicates that the module does not export a member named 'default', leading to a SyntaxError during module import.**

Error:
import thunk from "redux-thunk";
^^^^^
SyntaxError: The requested module 'redux-thunk' does not provide an export named 'default'

**import thunk from "redux-thunk";

const store = createStore(
reducer,
applyMiddleware(logger.default, thunk.default)
);**

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

1 participant