DEV Community

Discussion on: Explain React State & Props Like I'm Five

Collapse
 
nestedsoftware profile image
Nested Software • Edited

To briefly add to the other comments...

Any given React component may keep track of its own state - so that's the "state" part of your question. For example, a "Calendar" component might keep the selected date and the view mode (e.g. week, month) as part of its state.

React components are often nested inside other react components. Often when you create a component inside of another one, you may wish to pass some information from your parent component to the child component you are creating. That's the "props" part of your question.