What are Functional Components?
- Functional Components was introduced in React version 16.8
- These are simply JavaScript functions. These functions may or may not receive data as parameters.
- In the functional Components, the return value is the JSX code to render to the DOM tree.
- Functional Components are mostly used.
- It is Easy to use.
Follow the steps in this link - https://skylabtutorials.blogspot.com/2023/06/react-js-create-new-file-component.html
INTERVIEW QUESTION
- In which version of React, the functional components was introduced?
Answer :
React 16.8 - What is the shortcut way to write functional component structure in VS Code?
Answer :
Type rfc and press enter. - Can we create one component inside another component? Justify with an example.
Answer :
YES, Visit the link - https://skylabtutorials.blogspot.com/2023/06/react-js-create-one-component-inside.html
Comments
Post a Comment