Skip to content

Instantly share code, notes, and snippets.

@velotiotech
Created June 26, 2020 11:50
Show Gist options
  • Save velotiotech/d62692f9f806cc8aa1e562437adcbbb7 to your computer and use it in GitHub Desktop.
Save velotiotech/d62692f9f806cc8aa1e562437adcbbb7 to your computer and use it in GitHub Desktop.
render() {
return (
<div>
{this.state.timeThen > this.state.timeNow ? (
<>
<button onClick={() => { /* some action */ }} />
<button onClick={() => { /* another action */ }} />
</>
) : (
<button onClick={() => { /* yet another action */ }} />
)}
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment