The TODOs app is the new “Hello World” I was asked to answer a about a simple TODOs example, and I thought a detailed explanation for it would be helpful to any one starting to learn . Quora question React You can see the code in action (Make sure you execute it with ES6/Babel selected in the middle). I did not write that code, I am just going to explain it inline after each important concept. here The example is a simple TODOs app with 3 components: (the container and state manager) TodoList (presentational for the list of todos) TodoItems (controlled component to read a new ) TodoInput todo The first rendered interface looks like: The initial list renders with test items “red” and “blue”, then you can use the “Add” button to add more items to the list. Thanks for reading!
Share Your Thoughts