Create a new functional component, for example, Props1.js
Open App.js and pass data to Props1 component :
In the above,we are passed name from App component to Props1 component.
Now, open Props1.js and access the name data :
Create a new functional component, for example, Props2.js
Open App.js and pass data to Props2 component :
In the above,we are passed name & others (object) from App component to Props2 component.
Now, open Props2.js and access the data :
Github Links :
Comments
Post a Comment