Open jawkha opened 4 years ago
Overall, really good work. I have a few observations though which I have listed below: When you set up a React project using create-react-app, it also creates a .gitignore file in the project's root directory. It seems like you may have deleted it and that's why when you pushed your homework to GitHub in the absence of a .gitignore file, your node_modules folder was also uploaded. This is something you need to be more careful about. https://github.com/abedaarabi/hyf-homework/blob/459907f40e06dfaf36fcb0413e04c9048aa6a8e3/react/week1/to_do_app/src/Todos.js#L7 When iterating over the to do items, you have used the id property of each to do object as the key. However, as you can see below, two of the items have the same id. Keys in a list are required to be unique so that components can maintain their identity across updates. https://github.com/abedaarabi/hyf-homework/blob/459907f40e06dfaf36fcb0413e04c9048aa6a8e3/react/week1/to_do_app/src/App.js#L8-L9 This leads to some other bugs in the UI as well.
create-react-app
.gitignore
node_modules
to do
id
key
For the first week of React, this is still very impressive work. Keep it up!
thank you so much for the feedback :)
Overall, really good work. I have a few observations though which I have listed below: When you set up a React project using
create-react-app
, it also creates a.gitignore
file in the project's root directory. It seems like you may have deleted it and that's why when you pushed your homework to GitHub in the absence of a.gitignore
file, yournode_modules
folder was also uploaded. This is something you need to be more careful about. https://github.com/abedaarabi/hyf-homework/blob/459907f40e06dfaf36fcb0413e04c9048aa6a8e3/react/week1/to_do_app/src/Todos.js#L7 When iterating over theto do
items, you have used theid
property of eachto do
object as thekey
. However, as you can see below, two of the items have the sameid
. Keys in a list are required to be unique so that components can maintain their identity across updates. https://github.com/abedaarabi/hyf-homework/blob/459907f40e06dfaf36fcb0413e04c9048aa6a8e3/react/week1/to_do_app/src/App.js#L8-L9 This leads to some other bugs in the UI as well.For the first week of React, this is still very impressive work. Keep it up!