Last active
January 7, 2019 17:53
-
-
Save charbelrami/c5fc887cacb80be6cf8964a5c140de60 to your computer and use it in GitHub Desktop.
Interface
This file contains 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 useTodo from '../logic-hooks/useTodo'; | |
import TodoInput from '../components/TodoInput'; | |
import TodoList from '../components/TodoList'; | |
export default function TodoInterface() { | |
const { todos, newTodo, setNewTodo, addTodo } = useTodo(); | |
return ( | |
<> | |
<TodoInput newTodo={newTodo} setNewTodo={setNewTodo} addTodo={addTodo} /> | |
<TodoList todos={todos} /> | |
</> | |
); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment