awesome-repositories.com
Blog
MCP
awesome-repositories.com

Discover the best open-source repositories with AI-powered search.

ExploreCurated searchesOpen-source alternativesSelf-hosted softwareBlogSitemap
ProjectMCP serverAboutHow we rankPress
LegalPrivacyTerms
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
dgraham avatar

dgraham/delegated-events

0
View on GitHub↗
1,007 stars·50 forks·JavaScript·MIT·2 views

Delegated Events

Delegated-events is a JavaScript library designed for managing DOM interactions and component communication through centralized event handling. It provides utilities to implement event delegation, allowing developers to register a single listener on a parent element that triggers only when events originate from child elements matching specific CSS selectors.

The library distinguishes itself by integrating type-safe payload validation, which ensures that data exchanged between application components adheres to predefined structures. By consolidating multiple potential handlers into a single shared parent registration, the library reduces the total number of active event listeners and optimizes memory usage.

Beyond delegation, the project includes a system for dispatching custom events to facilitate decoupled communication between independent parts of an application. These tools standardize how web applications process user interactions and data, supporting consistent event management across complex interfaces.

Features

  • Event Delegation - Enables efficient event delegation by registering a single handler on a parent element that triggers only when events originate from children matching specific CSS selectors.
  • Event Payload Type Narrowing - Provides type-safe event payload validation, mapping custom event names to specific data structures to ensure data consistency and error-free development.
  • Custom Event Dispatchers - Facilitates communication between components by dispatching custom events with associated data payloads for decoupled interaction.
  • Event Bubbling Mechanisms - Relies on the standard browser event propagation phase to capture interactions at a parent node for centralized event management.
  • DOM & Event Handling - Provides a mechanism for handling events across multiple child elements from a common ancestor to reduce memory usage and simplify logic.
  • Event Listener Management - Reduces the total number of active event listeners by consolidating multiple potential handlers into a single shared parent registration.

Star history

Star history chart for dgraham/delegated-eventsStar history chart for dgraham/delegated-events

AI search

Explore more awesome repositories

Describe what you need in plain English — the AI ranks thousands of curated open-source projects by relevance.

Start searching with AI

Curated searches featuring Delegated Events

Hand-picked collections where Delegated Events appears.
  • DOM interaction library

Frequently asked questions

What does dgraham/delegated-events do?

Delegated-events is a JavaScript library designed for managing DOM interactions and component communication through centralized event handling. It provides utilities to implement event delegation, allowing developers to register a single listener on a parent element that triggers only when events originate from child elements matching specific CSS selectors.

What are the main features of dgraham/delegated-events?

The main features of dgraham/delegated-events are: Event Delegation, Event Payload Type Narrowing, Custom Event Dispatchers, Event Bubbling Mechanisms, DOM & Event Handling, Event Listener Management.

What are some open-source alternatives to dgraham/delegated-events?

Open-source alternatives to dgraham/delegated-events include: bendc/sprint — Sprint is a lightweight DOM manipulation and event handling library. It provides a minimal set of utilities for… facebook/react — React is a JavaScript library for building user interfaces based on a component-driven architecture and unidirectional… fabiospampinato/cash — Cash is a lightweight DOM manipulation library and HTML element wrapper designed as an alternative to jQuery for… hotwired/stimulus — Stimulus is a JavaScript behavior framework and client-side logic layer used to add interactive behavior to… sadanandpai/javascript-code-challenges — This repository is a collection of JavaScript coding challenges and a comprehensive interview guide. It provides… flightjs/flight — Flight is a JavaScript component framework and DOM interactivity library used to map behavioral logic to HTML nodes.…

Open-source alternatives to Delegated Events

Similar open-source projects, ranked by how many features they share with Delegated Events.
  • bendc/sprintbendc avatar

    bendc/sprint

    4,188View on GitHub↗

    Sprint is a lightweight DOM manipulation and event handling library. It provides a minimal set of utilities for selecting, modifying, and traversing elements within the browser document object model. The library utilizes a selector engine to isolate specific document nodes using CSS-like patterns and positional indices. It encapsulates raw DOM elements within a wrapper object to provide a consistent API for updating element attributes, styles, and content. The toolset covers browser event management for attaching and detaching interaction handlers, as well as document tree navigation to loca

    JavaScript
    View on GitHub↗4,188
  • facebook/reactfacebook avatar

    facebook/react

    245,669View on GitHub↗

    React is a JavaScript library for building user interfaces based on a component-driven architecture and unidirectional data flow.

    JavaScriptjavascriptuifrontend
    View on GitHub↗245,669
  • fabiospampinato/cashfabiospampinato avatar

    fabiospampinato/cash

    7,041View on GitHub↗

    Cash is a lightweight DOM manipulation library and HTML element wrapper designed as an alternative to jQuery for selecting and modifying elements in modern browsers. It functions as a modular DOM framework and JavaScript utility library, providing a system to wrap DOM nodes into actionable collections for batch processing. The project is built with a modular design that supports tree-shaking, allowing build tools to exclude unused methods to minimize the final bundle size. It provides mechanisms for extending the core functionality and collection prototypes to implement reusable plugins and c

    JavaScriptcashdomjavascript
    View on GitHub↗7,041
  • hotwired/stimulushotwired avatar

    hotwired/stimulus

    13,058View on GitHub↗

    Stimulus is a JavaScript behavior framework and client-side logic layer used to add interactive behavior to server-rendered HTML. It functions as a system of DOM component controllers that organize JavaScript logic into classes, allowing developers to enhance server-delivered markup without replacing the rendering process with a client-side framework. The framework uses data attributes to bind JavaScript classes to HTML elements and map DOM events to specific methods through document-level event delegation. It employs a lifecycle manager based on mutation observers to automatically instantiat

    TypeScript
    View on GitHub↗13,058
See all 30 alternatives to Delegated Events→