diff --git a/package.json b/package.json index 9a2d9d4..c349ce7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "data-transport", - "version": "4.2.1", + "version": "4.2.2", "description": "A simple and responsible transport", "main": "lib/index.js", "unpkg": "dist/index.umd.js", diff --git a/src/interface.ts b/src/interface.ts index b8d604e..3d111b4 100644 --- a/src/interface.ts +++ b/src/interface.ts @@ -1,11 +1,15 @@ import { transportKey, transportType } from './constant'; -import { listen } from './decorators'; export interface BaseInteraction { listen?: Record any>; emit?: Record any>; } +export type Reverse = { + emit: T['listen']; + listen: T['emit']; +}; + export type MergeInteraction< T extends BaseInteraction, U extends BaseInteraction