Esc

ws_connect

procedureextensionsince 0.36.1Source
  • macOS: ws_connect works on macOS
  • Linux: ws_connect works on Linux
  • Windows: ws_connect works on Windows
  • Wasm: ws_connect works on Wasm

Connects on the calling Io fiber, sharing Http's transport and TLS configuration. Example: connection, error := ws_connect("wss://example.org/chat"); defer ws_dispose(*connection).

Signature

ws_connect :: (
    url: string,
    config := Ws_Config.{},
    client: *Http.Client = null
) -> (Ws_Connection, Ws_Error)

See also