Skip to content

Latest commit

 

History

History
22 lines (15 loc) · 533 Bytes

README.md

File metadata and controls

22 lines (15 loc) · 533 Bytes

Events.ts

Events.ts is a Deno module that implements typings to the Node.js event emtter.

Example

deno run https://deno.land/x/events_ts/example.ts

or

import EventEmitter from 'https://deno.land/x/events_ts/mod.ts';

const emitter = new EventEmitter<{ message: [message: string] }>();

emitter.on('message', console.log);
emitter.emit('message', 'Hello, World!');