React JS - Create one component inside another component

In React, we can create one component inside another component.

Open App.js and create a new component inside App() function as shown below: 


(App.js)

In the above example, we have created and used Apple component inside App Component in App.js file.


Comments