question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[v5] Redux bindActionCreators warning triggered by import * as ... when importing actions

See original GitHub issue

Are you submitting a bug report or a feature request?

Bug

What is the current behavior?

image

What is the expected behavior?

No warning from bindActionCreators

What’s your environment?

React 15.6.1 Redux Form 5.3.6

Other information

See: https://github.com/reactjs/redux/pull/2279

I think the problem starts from here https://github.com/erikras/redux-form/blob/v5/src/createHigherOrderComponent.js#L2 - __esModule is present in the actions object.

Thanks, Raul

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:6
  • Comments:7

github_iconTop GitHub Comments

2reactions
thom-niccommented, Jun 20, 2017

I’m seeing the same behavior on redux-form v5.2.5.
It appears this warning was introduced in redux v3.7.0: reactjs/redux@1b154e0ba79ff Downgrading redux removes the warning.

This technically isn’t a redux-form issue, babel + es6 imports is what adds the __esModule key into the object when its transpiled. And redux own documentation suggests using import * as actionCreators from 'someModule' in this context.

Ref: reactjs/redux#2460

0reactions
lock[bot]commented, Jun 27, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Read more comments on GitHub >

github_iconTop Results From Across the Web

bindActionCreators - Redux
bindActionCreators (actionCreators, dispatch). Turns an object whose values are action creators, into an object with the same keys, ...
Read more >
How and When to use BindActionCreators | by Kristen Leach
At the top of your file, be sure to import all of your actions using an *, and use 'as' to specify a...
Read more >
unable to bind actions to component React Redux
You must pass Actions as the first argument to bindActionCreators instead of as an object function mapDispatch(dispatch) { return ...
Read more >
v5 → v6 Migration Guide - Redux Form
I would love to provide new API and provide deprecation warnings on the old API, but there is just no path from here...
Read more >
redux-messenger - npm
Redux actions & state management for working with user messages. ... To add the redux-messenger reducer to your project, import the reducer ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found