Skip to content

Files

Latest commit

 

History

History
 
 

autobahnjs

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

cljsjs/autobahnjs

ClojureScript wrapper for Autobahn|JS

[cljsjs/autobahnjs "0.12.0-0"] ;; latest release

This jar comes with deps.cljs as used by the Foreign Libs feature of the ClojureScript compiler. After adding the above dependency to your project you can require the packaged library like so:

(ns your-ns
  (:require [cljsjs.autobahn]))

(def ^:private ab js/autobahn)

(defn create-connection
    [config]
    (ab.Connection. (clj->js config))

(.open (:connection (create-connection {:ws-uri        "ws://localhost.de:8280/ws"
                                        :realm         "tour"
                                        :debug?        true
                                        :reconnect?    false})))