- Create
Class BasedComponent.- Create 2
class-based child components. Pass propsfromParent to child.- Create a
constructor. - Create a
state variableinside child. - Use
this.setStateto update it. - What if there are
multiple state variables? - Write a
console.logfor each lifecycle method. - Play with the
console logsto find out the correct order of their execution.
- Create 2
- Create interval inside
componentDidMount?- Use
clearIntervalto fix the issue caused by the interval
- Use
Coding
Folders and files
| Name | Name | Last commit date | ||
|---|---|---|---|---|
parent directory.. | ||||
Β | Β | |||
Β | Β | |||
Β | Β | |||
Β | Β | |||