---
title: "mitt 3.0.0 Breaking Changes on npm | Since.dev"
description: "What each mitt release removed, renamed or changed: 18 breaking changes in 2 versions on npm, each with its source."
canonical_url: https://since.dev/packages/npm/mitt
last_updated: 2026-12-04
---

# mitt breaking changes

mitt 3.0.0 (June 23, 2021) is its newest release with breaking changes, 12 of them. The first: Behavior changed off. Every breaking API change we have recorded in mitt on npm: 18 breaking changes in 2 versions. Below, its 2 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `3.0.1`, released July 4, 2023. [Source repository](https://github.com/developit/mitt)

Packages on npm run on Node.js. [Node.js end of life dates](https://since.dev/calendar/nodejs.md).

- From [2.0.0](#v-2-0-0) to [3.0.0](#v-3-0-0): 12 breaking changes in 1 version.

## mitt 3.0.0 breaking changes

mitt 3.0.0, released June 23, 2021: 12 breaking changes.

- **Behavior changed** `off`  

Calling off with a type and no handler now removes every listener of that type instead of doing nothing. Code that relied on the old behavior must pass a specific handler. [github.com](https://github.com/developit/mitt/releases/tag/3.0.0)
- **Signature changed** `default`  

Was function mitt(all?: EventHandlerMap): Emitter; now function mitt\<Events extends Record\<EventType, unknown>>(all?: EventHandlerMap\<Events>): Emitter\<Events>. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Emitter`  

Was interface Emitter; now interface Emitter\<Events extends Record\<EventType, unknown>>. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Emitter.all`  

Was all: EventHandlerMap; now all: EventHandlerMap\<Events>. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Emitter.emit`  

Was emit(type: '\*', event?: any): void emit\<T = any>(type: EventType, event?: T): void; now emit\<Key extends keyof Events>(type: Key, event: Events\[Key\]): void emit\<Key extends keyof Events>(type: undefined extends Events\[Key\] ? Key... [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Emitter.off`  

Was off(type: '\*', handler: WildcardHandler): void off\<T = any>(type: EventType, handler: Handler\<T>): void; now off(type: '\*', handler: WildcardHandler\<Events>): void off\<Key extends keyof Events>(type: Key, handler?... [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Emitter.on`  

Was on(type: '\*', handler: WildcardHandler): void on\<T = any>(type: EventType, handler: Handler\<T>): void; now on(type: '\*', handler: WildcardHandler\<Events>): void on\<Key extends keyof Events>(type: Key, handler: Handler\<Events\[Key\]>)... [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `EventHandlerList`  

Was type EventHandlerList = Array\<Handler>; now type EventHandlerList\<T = unknown> = Array\<Handler\<T>>. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `EventHandlerMap`  

Was type EventHandlerMap = Map\<EventType, EventHandlerList | WildCardEventHandlerList>; now type EventHandlerMap\<Events extends Record\<EventType, unknown>> = Map\<keyof Events | '\*', EventHandlerList\<Events\[keyof Events\]> |... [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `Handler`  

Was type Handler\<T = any> = (event?: T) => void; now type Handler\<T = unknown> = (event: T) => void. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `WildCardEventHandlerList`  

Was type WildCardEventHandlerList = Array\<WildcardHandler>; now type WildCardEventHandlerList\<T = Record\<string, unknown>> = Array\<WildcardHandler\<T>>. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)
- **Signature changed** `WildcardHandler`  

Was type WildcardHandler = (type: EventType, event?: any) => void; now type WildcardHandler\<T = Record\<string, unknown>> = (type: keyof T, event: T\[keyof T\]) => void. [npmjs.com](https://www.npmjs.com/package/mitt/v/3.0.0)

## mitt 2.0.0 breaking changes

mitt 2.0.0, released May 26, 2020: 6 breaking changes.

- **Removed** `"mitt"`  

"mitt" was removed in mitt 2.0.0 [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)
- **Removed** `mitt`  

The optional event map passed to mitt() is now a Map rather than a plain object. Code that passes an object map or reads events from it as properties must switch to new Map() and map.get(). [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)
- **Renamed** `"mitt".Emitter`  

Use Emitter instead. [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)
- **Signature changed** `"mitt".Emitter.emit`  

Was emit(type: string, event?: any): void; now emit(type: "\*", event?: any): void emit\<T = any>(type: EventType, event?: T): void. [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)
- **Signature changed** `"mitt".Emitter.off`  

Was off(type: string, handler: Handler): void; now off(type: EventType, handler: Handler): void. [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)
- **Signature changed** `"mitt".Emitter.on`  

Was on(type: string, handler: Handler): void; now on(type: EventType, handler: Handler): void. [npmjs.com](https://www.npmjs.com/package/mitt/v/2.0.0)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
