Today I Learned - Rocky Kev

Tagged “events”

  1. TIL Event Delegation

    Event delegation is one of the most helpful patterns for DOM events! Adding too many event listeners means JavaScript is storing it all in memory. Event Delegation lets you store one listener, that then looks for the target.

  2. TIL using Event Delegation

    It's cheaper for the browser to track one event and fire it on every click that it is to manage multiple events.

  3. TIL how to remove a event listener

    Maybe you have a situation where you only want the event to fire once.

  4. TIL oncontextmenu feature for right-clicking

    The oncontextmenu property lets us assign an event handler function when the right mouse button is clicked on the browser tab.

  5. TIL Event Listeners in devtools

    Today I learned that you can identify the Event Listener directly in the Devtools!

  6. TIL the difference between throttling and debouncing

    Throttling enforces a maximum number of times a function can be called over time. Debouncing enforces that a function not be called again until a certain amount of time has passed without it being called.

See all tags.