   (connections-available re)
 
   (evaluate re "44")
+
+  (negotiate-id (:ring-request @scratch) @*connections*)
 
   scratch
   *connections*

;; Websocket REPL
;; --------------------------------------------------------------

(goog-define websocket-url "ws://localhost:3449/figwheel-ws")

(def state (atom {}))
(def storage (storage-factory/createHTML5SessionStorage "figwheel.repl"))


(defn connections-available [repl-env]
  (sort-by
   :created-at >
   (filter (or (some-> repl-env :connection-filter deref)
               identity)
           (vals @*connections*))))

(defn wait-for-connection [repl-env]
  (loop []
