Skip to content

Instantly share code, notes, and snippets.

@zapkub
Created November 15, 2018 04:49
Show Gist options
  • Save zapkub/84936cd5a71445a1f87b82a2fee6f2c1 to your computer and use it in GitHub Desktop.
Save zapkub/84936cd5a71445a1f87b82a2fee6f2c1 to your computer and use it in GitHub Desktop.
const TodosApp = () => {
// Declare every state we need to store
const [filter, setFilter] = React.useState<TodoState["filter"]>("All");
const [todos, setTodo] = React.useState<TodoState["todos"]>([]);
const [textInput, setTextInput] = React.useState<TodoState["textInput"]("");
return ( /** implement UI */ )
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment