UNPKG

onemon

Version:

Run a npm script as a deamon, once

19 lines (18 loc) 535 B
/// <reference types="node" /> import { EventEmitter } from 'events'; interface IPCServerOptions { socketPath: string; } export declare class IPCServer extends EventEmitter { private server; private socketPath; private encoder; private socketToClient; private clientToSocket; constructor(options: IPCServerOptions); listen(): Promise<void>; close(): Promise<void>; send(clientId: string, topic: string, message?: string): void; broadcast(topic: string, message?: string): void; } export {};