Question · JavaScript and TypeScript course · Module 8: Events and the DOM

IntersectionObserver

What is IntersectionObserver used for?

Answer options

  • To observe changes in element sizes
  • To observe changes in DOM attributes
  • To detect whether an element is visible in the viewport
  • To monitor event listener performance

You can check the correct answer by solving this task in the CodeWorlds game.