UNPKG

exthos

Version:

stream processing in nodejs using the power of golang

16 lines (12 loc) 316 B
import * as exthos from "../../dist/index.js"; let engine = new exthos.Engine({}); engine.useDefaultEventHandler({ "engine.fatal": (eventObj) => { console.log("\nTest EXITED with CODE=1", JSON.stringify(eventObj)); process.exit(1); }, }); engine.start(); setTimeout(() => { engine.stop(); }, 3000);