# event-delegation

Published articles for event-delegation.

This is one page of public article previews, not the complete archive. Follow Next page to continue. Summaries are not the original full articles.

## Understanding JavaScript Event Bubbling and Delegation Through an Accordion Refactor

DevFeed: [Understanding JavaScript Event Bubbling and Delegation Through an Accordion Refactor](<https://devfeed.tech/articles/understanding-javascript-event-bubbling-and-delegation-through-an-accordion-refactor-63981.md>)

Original publisher: [Read original article](<https://hackernoon.com/understanding-javascript-event-bubbling-and-delegation-through-an-accordion-refactor?source=rss>)

Author: Osaro Iyoha

Published: 2026-10-02T15:13:47Z

Content type: tutorial

Language: en

Sources: [HackerNoon](<https://devfeed.tech/sources/hackernoon.md>)

Topics: [Web Development](<https://devfeed.tech/topics/web-development.md>), [JavaScript](<https://devfeed.tech/topics/javascript.md>)

Tags: [dom-events](<https://devfeed.tech/tags/dom-events.md>), [dom-manipulation](<https://devfeed.tech/tags/dom-manipulation.md>), [event-bubbling](<https://devfeed.tech/tags/event-bubbling.md>), [event-delegation](<https://devfeed.tech/tags/event-delegation.md>), [event-listeners](<https://devfeed.tech/tags/event-listeners.md>), [javascript](<https://devfeed.tech/tags/javascript.md>), [javascript-fundamentals](<https://devfeed.tech/tags/javascript-fundamentals.md>), [refactor](<https://devfeed.tech/tags/refactor.md>), [refactoring](<https://devfeed.tech/tags/refactoring.md>)

### AI overview

A developer refactors a JavaScript accordion from separate click listeners tied together by parallel NodeLists to one delegated listener on the parent. The article explains how bubbling, event.target, .closest(), and DOM relationships identify the clicked accordion item, and shows built-in classList methods for toggling state. Delegation also handles accordion items added later without attaching new listeners.

### Source excerpt

A developer revisits an old JavaScript accordion to understand event bubbling, event delegation, .closest(), and cleaner ways to work with the DOM.

## Building the SoundCloud mobile site using backbone.js

DevFeed: [Building the SoundCloud mobile site using backbone.js](<https://devfeed.tech/articles/building-the-soundcloud-mobile-site-using-backbone-js-2007.md>)

Original publisher: [Read original article](<https://developers.soundcloud.com/blog//building-the-soundcloud-mobile-site-using-backbone.js>)

Published: 2011-08-02T00:00:00Z

Content type: article

Language: en

Sources: [SoundCloud Backstage](<https://devfeed.tech/sources/soundcloud-backstage-blog.md>)

Topics: [Backbone.js](<https://devfeed.tech/topics/backbonejs.md>), [Front end](<https://devfeed.tech/topics/frontend.md>), [Web app](<https://devfeed.tech/topics/webapp.md>), [mobile optimization](<https://devfeed.tech/topics/mobile-optimization.md>), [Mobile](<https://devfeed.tech/topics/mobile.md>), [HTML](<https://devfeed.tech/topics/html.md>)

Tags: [android](<https://devfeed.tech/tags/android.md>), [api](<https://devfeed.tech/tags/api.md>), [architecture](<https://devfeed.tech/tags/architecture.md>), [audio](<https://devfeed.tech/tags/audio.md>), [browser](<https://devfeed.tech/tags/browser.md>), [cache](<https://devfeed.tech/tags/cache.md>), [client](<https://devfeed.tech/tags/client.md>), [engine](<https://devfeed.tech/tags/engine.md>), [event-delegation](<https://devfeed.tech/tags/event-delegation.md>), [fixed](<https://devfeed.tech/tags/fixed.md>), [flexible](<https://devfeed.tech/tags/flexible.md>), [framework](<https://devfeed.tech/tags/framework.md>), [js](<https://devfeed.tech/tags/js.md>), [mobile](<https://devfeed.tech/tags/mobile.md>)

### AI overview

SoundCloud built a mobile browser site for iOS and Android to let users open shared tracks without loading the desktop site or depending on a native app being installed. A jQuery Mobile prototype showed that a single-page API client was feasible, but its routing and theming did not fit pages generated dynamically from API results; mobile audio streaming also required workarounds. The team chose Backbone.js for its compact, flexible structure, using jquery-tmpl with templates limited to output and iteration, model toJSON methods for presentation data, and a decoration step before DOM insertion. Extensions added pushState URL handling and a sessionStorage-backed client cache. On navigation, the router builds a model and view; the view fetches data, renders and decorates the template, then sets up delegated interaction handlers. The excerpt says a proxy was later added to decorate the API and work around WebKit bugs, while most app behavior remained client-side.

### Source excerpt

Until early this year, there was a gap. A gap between the desktop-targeted main SoundCloud site, what we call the 'mothership', and the...