addListener Method
Establish a handler to receive messages for a channel through a socket.
addListener(channel: string, listener: IpcListener): RemoveFunction
note returns A function to call to remove the listener.
Parameter | Type | Description |
---|---|---|
channel | string | The name of the channel for the messages. Must begin with the iTwinChannel prefix. |
listener | IpcListener | A function called when messages are sent over channel |
Returns - RemoveFunction
Defined in
- core/common/src/ipc/IpcSocket.ts Line 56
Last Updated: 20 June, 2023