copy method
Instantiates and returns a functionally identical object to oneself.
Outside of tests, this method should only ever be called by
InstanceManager
.
Subclasses should always override their parent's implementation of this method.
Implementation
@override
JavaScriptChannel copy() {
return JavaScriptChannel.detached(channelName, postMessage: postMessage);
}