20. What is Redux in the context of a React application?

  • A third-party routing library for React applications.
  • A state management library for React applications.
  • A testing library for React applications.
  • A component library for React applications.

21. What is the purpose of the "useEffect" hook in React?

  • To manage state in a React component.
  • To create a context object in a React application.
  • To consume data from a context object in a React component.
  • To perform side effects in a React component, such as making API calls or manipulating the DOM.

22. What is the purpose of the "dispatch" function in Redux?

  • To update the state of a React component.
  • To update the state of a Redux store.
  • To create a new Redux store.
  • To subscribe to changes in a Redux store.

23. What is an action in the context of Redux?

  • An event that triggers a side effect in a React component.
  • A function that updates the state of a Redux store.
  • A configuration object that defines the behavior of a Redux store.
  • An object that describes a state change in a Redux store, including a type and payload.

Leave a Reply