OpenerConnection
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
In extends MessageMap |
Out extends MessageMap |
R |
Properties
Section titled “Properties”readonly ready: Promise<void>;Resolves once the opener acknowledges the ready handshake.
Methods
Section titled “Methods”close()
Section titled “close()”close(): void;Tell the opener we’re going away, then close this window.
Returns
Section titled “Returns”void
finish()
Section titled “finish()”finish(result): void;Deliver the terminal result to the opener. Does not close the window.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
result | R |
Returns
Section titled “Returns”void
on<K>(type, handler): () => void;Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
K extends string |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
type | K |
handler | (payload) => void |
Returns
Section titled “Returns”() => void
post()
Section titled “post()”post<K>(type, payload): void;Queued until the handshake completes.
Type Parameters
Section titled “Type Parameters”| Type Parameter |
|---|
K extends string |
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
type | K |
payload | Out[K] |
Returns
Section titled “Returns”void