Liking cljdoc? Tell your friends :D
ClojureScript only.

haslett.client

A namespace for opening WebSockets in ClojureScript.

A namespace for opening WebSockets in ClojureScript.
raw docstring

closecljs

(close stream)

Close a stream opened by connect.

Close a stream opened by connect.
sourceraw docstring

connectcljs

(connect url)
(connect url options)

Create a WebSocket to the specified URL, and returns a 'stream' map of four keys:

:socket - contains the WebSocket object :close-status - a promise channel that contains the final close status :source - a core.async channel to read from :sink - a core.async channel to write to

Takes the following options:

:format - a formatter from haslett.format :source - a custom channel to use as the source :sink - a custom channel to use as the sink :protocols - passed to the WebSocket, a vector of protocol strings :binary-type - passed to the WebSocket, may be :blob or :arraybuffer

Create a WebSocket to the specified URL, and returns a 'stream' map of four
keys:

  :socket       - contains the WebSocket object
  :close-status - a promise channel that contains the final close status
  :source       - a core.async channel to read from
  :sink         - a core.async channel to write to

Takes the following options:

  :format      - a formatter from haslett.format
  :source      - a custom channel to use as the source
  :sink        - a custom channel to use as the sink
  :protocols   - passed to the WebSocket, a vector of protocol strings
  :binary-type - passed to the WebSocket, may be :blob or :arraybuffer
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close