Description
EVT is a typesafe replacement for the Node.js EventEmitter, written for TypeScript projects that want the compiler to check their events. You declare each event with its own type and attach handlers to it, so mistakes in event names or payloads show up at compile time rather than at runtime. Handlers can be attached only when an event matches a filter, which covers cases the plain EventEmitter cannot handle cleanly. The waitFor method returns a promise that resolves on the next matching event and removes its listener afterward, so you do not have to detach listeners by hand. The library is designed to work with TypeScript and runs in Deno, Node.js, the browser and React Native. You can install it with npm install --save evt, or import it from its Deno module. The site describes it as accessible yet powerful and built to make the most of TypeScript. The source is on GitHub under the MIT License, with documentation on the site.…
Highlights
- Strongly typed events for TypeScript
- Filtered event handlers
- waitFor for one-off promises
- Runs on Deno, Node.js, browsers and React Native
- Installs from npm
- MIT License
Ratings & Reviews
No ratings yet
Be the first to rate Evt.
People also visit
Deno Deploy
One simple platform for anything that runs with JavaScript or Typescript
Evt FAQ
What is EVT?
A typesafe replacement for the Node.js EventEmitter, for TypeScript projects.
Where does it run?
Deno, Node.js, the browser and React Native, according to the site.
How do I install it?
Run npm install --save evt. In Deno, import it from the module URL shown on the site.
What does waitFor do?
It waits for the next event that matches and then removes its listener, so you do not have to detach it yourself.
Is it free?
Yes. It is released under the MIT License and the source is on GitHub at garronej/evt.
What are the best Evt alternatives?
Popular alternatives to Evt include Eventemitter3, React Typescript Electron Sample With Create React App And Electron Builder and Lifo. See all Evt alternatives












