Skip to content

Installation

ESMitter can be installed using your package manager of choice and is also available on jsr.io.

sh
npm install esm-itter
sh
yarn add esm-itter
sh
pnpm add esm-itter
sh
deno add jsr:@tillsanders/esm-itter

Compatibility

ESMitter requires Node > v18 or a browser with EcmaScript modules (ESM) support and also supports Deno.

Import

ESMitter uses named exports. You can import the base class like this:

typescript
import { ESMitter } from "esm-itter";
typescript
import { ESMitter } from "@tillsanders/esm-itter";