package ocaml-vdom

  1. Overview
  2. Docs
type t
val t_of_js : Ojs.t -> t
val t_to_js : t -> Ojs.t
type ready_state =
  1. | Connecting
  2. | Open
  3. | Closing
  4. | Closed
val create : string -> ?protocols:string list -> unit -> t
val send : t -> string -> unit
val close : t -> ?code:int -> ?reason:string -> unit -> unit
val binary_type : t -> string
val set_binary_type : t -> string -> unit
val ready_state : t -> ready_state
val add_event_listener : t -> Event.kind -> (Event.t -> unit) -> bool -> unit
module CloseEvent : sig ... end
OCaml

Innovation. Community. Security.