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

Quiz: Event Context

What does 'this' refer to in a traditional event handler function?

Answer options

  • To the element on which the event listener was registered
  • To the window object
  • To the element that triggered the event
  • To the event object

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