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

Passing async response data as prop. #130

Open
ttbrijkishor opened this issue Jun 21, 2018 · 1 comment
Open

Passing async response data as prop. #130

ttbrijkishor opened this issue Jun 21, 2018 · 1 comment

Comments

@ttbrijkishor
Copy link

Hi,

I have a use case where I need to pass data as prop to component and need to avoid putting it into redux store. Data is coming from asyncItem. I have gone through the decorator code but didn't find a solution.

Any suggestion would be great help.Thanks.

Regards,
Brij Kishor

@finom
Copy link

finom commented Jun 22, 2018

@ttbrijkishor see https://github.com/makeomatic/redux-connect/blob/master/docs/API.MD#asyncconnect-decorator

The interface is similar to react-redux connect. The key field of each object will be used to connect data returned from from promise to both the redux state and the corresponding prop in the component. So in example above you'll have this.props.lunches.

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

2 participants