React JS Quiz
HomeBlogPrivacy PolicyContact UsInterview QuestionsNewTutorialsBuy me a coffee
  1. Home
  2. /Quizzes
  3. /Hooks
  4. /Custom Hooks Quiz

Custom Hooks Quiz

Test your knowledge of custom Hooks in React, including naming, extraction, dependencies, reusable logic, and common pitfalls.

20 questions · free · answers explained

Start the quiz
Advertisement

All questions in this quiz

  1. What is a custom Hook in React?
  2. How should a custom Hook name begin?
  3. Why does the use prefix matter for custom Hooks?
  4. Can a custom Hook call built-in Hooks like useState and useEffect?
  5. What do custom Hooks share between components?
  6. If two components call the same custom Hook, what happens to their state?
  7. When is it usually a good idea to extract a custom Hook?
  8. What should a custom Hook usually return?
  9. Which custom Hook name is most appropriate for tracking online status?
  10. Should a regular utility function that does not call Hooks start with use?
  11. Can custom Hooks accept arguments?
  12. What should happen to reactive values used inside a custom Hook effect?
  13. Why should custom Hooks remain pure during render?
  14. What is a drawback of vague custom Hooks like useMount?
  15. Which custom Hook name best describes connecting to a chat room?
  16. Can a custom Hook call another custom Hook?
  17. Where may a custom Hook be called?
  18. What is a common benefit of extracting a custom Hook?
  19. What does useDebugValue help with in custom Hooks?
  20. What is the best sign that a custom Hook API is too abstract?

Prefer to read first? React interview questions with written answers.

Support the developer