Created
June 28, 2018 00:30
-
-
Save nahumzs/de633b08fecb5e9623a2fb4f05f4de67 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
import React from "react"; | |
import HoverState from "./HoverState"; | |
export default class RenderProps extends React.Component { | |
render() { | |
return ( | |
<HoverState> | |
{isHover => { | |
if (isHover) { | |
return <button>🦁</button>; | |
} | |
return <button>🦄</button>; | |
}} | |
</HoverState> | |
); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment