UNPKG

interprocess

Version:

A scalable and type-safe Electron IPC management tool with enhanced DX

9 lines (8 loc) 508 B
import type { MainHandler, ProcessKeys, IPCFactoryProps } from '../types'; declare type MainHandle<MainKeys extends string, Main extends { [Property in MainKeys]: Main[Property]; }> = { [Property in MainKeys]: MainHandler<Property, Main[Property]>; }; export declare function createMainHandlers<T extends IPCFactoryProps<T>>(props: T): MainHandle<ProcessKeys<import("../types").IPC<T["main"], Electron.IpcMainInvokeEvent>>, import("../types").IPC<T["main"], Electron.IpcMainInvokeEvent>>; export {};