reagent/env/dev/devsetup.cljs
Dan Holmsand ed06312eaf Make render force already mounted components to update by default
This should make using Reagent with figwheel more convenient (no need
for force-update-all). Add a fourth argument to render that controls
the updating.
2014-12-07 10:00:47 +01:00

24 lines
509 B
Clojure

(ns devsetup
(:require [demo :as site]
[runtests]
[reagent.core :as r]
[figwheel.client :as fw :include-macros true]))
(defn test-results []
[runtests/test-output-mini])
;; (defn on-update []
;; (r/force-update-all)
;; (runtests/run-tests))
(defn start! []
(demo/start! {:test-results test-results})
(runtests/run-tests))
(when r/is-client
(fw/watch-and-reload
:websocket-url "ws://localhost:3449/figwheel-ws"
:jsload-callback #(start!)))
(start!)