Tag view

#refs

Cross-subject tag search for related interview cards.

Clear

Results update as you type. Press / to jump straight into search.

Tagged with refs

2 cards

React Easy Theory

useRef, refs vs state, and DOM access in React

useRef holds mutable values that do not trigger re-renders and is commonly used for DOM access or persistent instance-like values.

  • Refs do not cause re-renders
  • Useful for DOM nodes and mutable escape hatches
  • State should drive visible UI

useRef, refs vs state, and DOM access in React