reading-notes

Code Fellows Notes

View the Project on GitHub stephnitis/reading-notes

Readings: Introduction to React and Components

Component-Based Architecture

Characteristics of Components:

Advantages:

What is Props and How to Use it in React

“Props” is a special keyword in React, which stands for properties and is being used for passing data from one component to another.

But the important part here is that data with props are being passed in a uni-directional flow. (one way from parent to child)

props data is read-only

How are Props used in React?

  1. define an attribute and its value(data)
  2. pass it to child component(s) by using Props
  3. render the Props Data

What is the flow of props?