Skip to content

Instantly share code, notes, and snippets.

@tristanpendergrass
Created February 13, 2018 17:00
Show Gist options
  • Save tristanpendergrass/322e0d201097ddba71ae199ffea47747 to your computer and use it in GitHub Desktop.
Save tristanpendergrass/322e0d201097ddba71ae199ffea47747 to your computer and use it in GitHub Desktop.
const MyComponent = ({ foo }) => (
<div>{foo}</div>
);
// using connect
const FinalConnected = connect(mapStateToProps)(MyComponent);
// using subjects
const FinalSubjected = () => (
<Foo render={({ get }) => (
<MyComponent foo={get()} />
)} />
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment