Skip to content

Instantly share code, notes, and snippets.

@ryardley
Last active October 31, 2018 02:32
Show Gist options
  • Save ryardley/411bc849c6a3b9533b830a94f3979ae6 to your computer and use it in GitHub Desktop.
Save ryardley/411bc849c6a3b9533b830a94f3979ae6 to your computer and use it in GitHub Desktop.
function RenderFunctionComponent() {
const [firstName, setFirstName] = useState("Rudi");
const [lastName, setLastName] = useState("Yardley");
return (
<Button onClick={() => setFirstName("Fred")}>Fred</Button>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment