jsNewRuntime function

Pointer<JSRuntime> jsNewRuntime(
  1. _JSChannel callback,
  2. ReceivePort port
)

Implementation

Pointer<JSRuntime> jsNewRuntime(
  _JSChannel callback,
  ReceivePort port,
) {
  final rt = _jsNewRuntime(Pointer.fromFunction(channelDispacher));
  runtimeOpaques[rt] = _RuntimeOpaque(callback, port);
  return rt;
}