status-mobile/src/syng_im/navigation.cljs
michaelr d54d6555a4 moved re-frame app to root folder
Former-commit-id: 5a3b923b0c32e5e900b89e984393822ce6a15abc
2016-04-04 19:21:10 +03:00

18 lines
423 B
Clojure

(ns syng-im.navigation)
(def ^{:dynamic true :private true} *nav-render*
"Flag to suppress navigator re-renders from outside om when pushing/popping."
true)
(defn nav-pop [nav]
(binding [*nav-render* true]
(.pop nav)))
(defn nav-push [nav route]
(binding [*nav-render* true]
(.push nav (clj->js route))))
(defn nav-replace [nav route]
(binding [*nav-render* true]
(.replace nav (clj->js route))))