mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Fix spelling and grammar in Ipc docs (#2880)
Signed-off-by: Sebastian Malton <sebastian@malton.name>
This commit is contained in:
parent
bfcb6c7e36
commit
81a35737fd
@ -30,7 +30,7 @@ With this sort of communication the caller needs to wait for the result from the
|
|||||||
This is accomplished by `await`-ing the returned `Promise<any>`.
|
This is accomplished by `await`-ing the returned `Promise<any>`.
|
||||||
|
|
||||||
This is a unidirectional form of communication.
|
This is a unidirectional form of communication.
|
||||||
Only `renderer` can initiate this kind of request, and only `main` can and respond to this kind of request.
|
Only `renderer` can initiate this kind of request, and only `main` can receive and respond to this kind of request.
|
||||||
|
|
||||||
## Registering IPC Handlers and Listeners
|
## Registering IPC Handlers and Listeners
|
||||||
|
|
||||||
|
|||||||
@ -37,7 +37,7 @@ export abstract class IpcRenderer extends IpcRegistrar {
|
|||||||
* a component then putting the returned value in a `disposeOnUnmount` call will suffice.
|
* a component then putting the returned value in a `disposeOnUnmount` call will suffice.
|
||||||
* @param channel The channel to listen for broadcasts on
|
* @param channel The channel to listen for broadcasts on
|
||||||
* @param listener The function that will be called with the arguments of the broadcast
|
* @param listener The function that will be called with the arguments of the broadcast
|
||||||
* @returns An optional disopser, Lens will cleanup even if this is not called
|
* @returns An optional disposer, Lens will cleanup even if this is not called
|
||||||
*/
|
*/
|
||||||
listen(channel: string, listener: (event: Electron.IpcRendererEvent, ...args: any[]) => any): Disposer {
|
listen(channel: string, listener: (event: Electron.IpcRendererEvent, ...args: any[]) => any): Disposer {
|
||||||
const prefixedChannel = `extensions@${this[IpcPrefix]}:${channel}`;
|
const prefixedChannel = `extensions@${this[IpcPrefix]}:${channel}`;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user