Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
reactjs function component with props demo
const todos = [];
todos.push("Buy a big doll");
todos.push("Do yoga");
todos.push("Review component article");
function TodoList(props) {
return (
<div className="todo-lists">
function App() {
return (
<TodoList data={todos}/>
ReactDOM.render(<App />, document.getElementById('root'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment