primus/eventemitter3

EventEmitter3 - Because there's also a number 2. And we're faster.

View on GitHub ↗Jump to charts ↓

Summary Information

Updated 9 minutes ago
Type:Library / SDKCategory(s):Core & Utility LibrariesLanguages & Runtimes
Added to GitGenius on September 19th, 2026
Created on September 25th, 2013
Open Issues & Pull Requests: 22 (+0)
GitHub issues: Enabled
Number of forks: 236
Total Stargazers: 3,538 (+0)
Total Subscribers: 35 (+0)

Repository Insights (GitGenius)

Median issue/PR response: 3.0 days
Mean response time: 14.1 days
90th percentile: 72.6 days
Tracked items: 8

Most active contributors

Sign in to see contributor activity.

Charts & Analytics

Fetching additional details & charts...

Issue Activity (beta)

Open issues: 5
New in 7 days: 0
Closed in 7 days: 0
Avg open age: 557 days
Stale 30+ days: 5
Stale 90+ days: 5

Recent activity

Opened in 7 days: 0
Closed in 7 days: 0
Comments in 7 days: 0
Events in 7 days: 0

Top labels

No label distribution available yet.

Most active issues this week

No issue events were indexed in the last 7 days.

Detailed Description

It provides a faster alternative to the standard Node.js EventEmitter through micro-optimization of code paths, while maintaining API compatibility with the built-in implementation.

The tool solves the problem of event handling overhead by stripping away less commonly used features and optimizing the remaining core functionality. It removes domain support, the newListener and removeListener events, and methods like setMaxListeners and prependListener. In exchange, it adds support for custom context binding on events, eliminating the need to use fn.bind for setting the this value during emission. The removeListener method also behaves differently, removing all matching listeners rather than just the first.

EventEmitter3 suits projects where performance matters and the removed features are not required. It works as a drop-in replacement for the standard EventEmitter in both Node.js and browser environments, written in ECMAScript 3 for broad compatibility with older platforms. The README does not compare it to other third-party event emitters, only to Node.js's built-in implementation.

The project maintains an active test suite that can be run with npm test, and includes benchmarks available after cloning the repository and installing dependencies in the benchmarks folder. The codebase is written in a way that supports very old JavaScript standards and browser versions, indicating a commitment to broad compatibility across environments.