How do you get parameters from the URL in React Router?
useParams hook
Which hook is used to manage state in a functional component?
useState
Which are synthetic events in React ?
onClick, onChange, onBlur
Why do we use event.stopPropagation()?
To stop the event from bubbling up the DOM tree
Which method is used when submitting a form in React?
onSubmit
What does the value attribute in an input field do?
It sets the default/current value of the input field
What does onChange do in an input field?
Calls a function when the input value changes
What is Yup used for?
A validation library for JavaScript
Which Yup method checks a string using a regular expression?
matches()
What is ReactJS?
A front-end web development library
What is a React component?
A reusable part of the user interface
Which statement is true about functional components?
They are defined using a function that returns JSX
What is the difference between props and state?
Props are immutable; state is mutable
Why do we use the key attribute in lists?
To give each item a unique identity
How do you create a functional component?
By writing a function that returns JSX