( _channel: Channel, _type: keyof IPublishChannels[Channel], message: string, )
| 35 | } |
| 36 | |
| 37 | export function parsePublishedEvent<Channel extends keyof IPublishChannels>( |
| 38 | _channel: Channel, |
| 39 | _type: keyof IPublishChannels[Channel], |
| 40 | message: string, |
| 41 | ): IPublishChannels[Channel][typeof _type] { |
| 42 | return getSuperJson<IPublishChannels[Channel][typeof _type]>(message)!; |
| 43 | } |
| 44 | |
| 45 | export function subscribeToPublishedEvent< |
| 46 | Channel extends keyof IPublishChannels, |
no test coverage detected