Created
June 4, 2015 17:28
-
-
Save anthonyshort/4540efdb779ad18d719c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const Parent = { | |
render (component, updateState) { | |
function onChange () { | |
updateState({ parentChanged: 'yay' }) | |
} | |
return <Child onChange={onChange} /> | |
} | |
} | |
const Child = { | |
render ({ props }) { | |
return <div onClick={props.onchange}>Click</div> | |
} | |
} | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment