Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36
Chrome 114
Linux
Desktop
one year ago
Test name Executions per second
Native Event listeners 175.6 Ops/sec
Native Event listener with callbacks array 4612.3 Ops/sec
Custom EventTarget 164.7 Ops/sec
Custom EventTarget with callbacks array 6011.3 Ops/sec
Fake listeners array 24370.8 Ops/sec
Tests:
  • Native Event listeners

  • Native Event listener with callbacks array

  • Custom EventTarget

  • Custom EventTarget with callbacks array

  • Fake listeners array