Skip to main content

MessageEvent

interface MessageEvent
extends Event

Type Parameters Jump to heading

Properties Jump to heading

Returns the data of the message.

readonly
Jump to headingorigin: string

Returns the origin of the message, for server-sent events.

Returns the last event ID string, for server-sent events.

readonly
Jump to headingports: ReadonlyArray<MessagePort>

Returns transferred ports.

deprecated
Jump to headinginitMessageEvent(
type: string,
bubbles?: boolean,
cancelable?: boolean,
data?: any,
origin?: string,
lastEventId?: string,
source?: MessageEventSource | null,
ports?: MessagePort[],
): void
Back to top