Worker.Shared
Shared workers.
type t
The type for SharedWorker objects.
SharedWorker
val create : ?opts:opts -> Jstr.t -> t
create ~opts uri creates a shared worker that executes the script uri. This may throw a Jv.Error exception.
create ~opts uri
uri
Jv.Error
val as_target : t -> Brr.Ev.target
as_target w is w as an event target.
as_target w
w
val port : t -> Brr_io.Message.Port.t
port w is the port of w.
port w