W3cubDocs

/Haxe JavaScript

MessagePort

package js.html

extends EventTarget

@:native("MessagePort") Available on js

The MessagePort interface of the Channel Messaging API represents one of the two ports of a MessageChannel, allowing sending of messages from one port and listening out for them arriving at the other.

Documentation MessagePort by Mozilla Contributors, licensed under CC-BY-SA 2.5.

See:

Variables

onmessage:Function

Methods

close ():Void

postMessage (message:Dynamic, ?transferable:Array<Dynamic>):Void

Throws:

null DOMError

start ():Void

© 2005–2018 Haxe Foundation
Licensed under a MIT license.
https://api.haxe.org/js/html/MessagePort.html