UNPKG

381 BTypeScriptView Raw
1import { Observable } from 'rxjs';
2/**
3 * @publicApi
4 */
5export interface MessageHandler<TInput = any, TContext = any, TResult = any> {
6 (data: TInput, ctx?: TContext): Promise<Observable<TResult>> | Promise<TResult>;
7 next?: (data: TInput, ctx?: TContext) => Promise<Observable<TResult>> | Promise<TResult>;
8 isEventHandler?: boolean;
9 extras?: Record<string, any>;
10}