(Functional-component and Class-component)
Demo: https://miahsuwork.github.io/react-todo
藉由簡單的 todo list 比較 Functional-component 跟 Class-component 寫法上的差異
- 新增 todo、刪除 todo、改變狀態 todo
- 將資料儲存於 LocalStorage
├── README.md
├── build
├── package-lock.json
├── package.json
├── public
└── src
├── App.css
├── App.js
├── App.test.js
├── TodoClass.js
├── TodoFunctional.js
├── assets
├── index.css
├── index.js
├── reportWebVitals.js
├── setupTests.js
└── style.scss
Runs the app in the development mode. Open http://localhost:3000 to view it in your browser.
The page will reload when you make changes. You may also see any lint errors in the console.