(alter-state! {:keys [var inst]} value)
(alter-state! {:keys [inst]} value)
(add-watcher this ks watcher)
(on-change this k)
(cleanup-if-dirty state reason)
in case a namespace is recompiled without calling (mount/stop), a running state instance will still be running. this function stops this 'lost' state instance. it is meant to be called by defstate before defining a new state
in case a namespace is recompiled without calling (mount/stop), a running state instance will still be running. this function stops this 'lost' state instance. it is meant to be called by defstate before defining a new state
(defstate state & body)
defines a state (a.k.a. a stateful component). restarts on recompilation. pass ^{:on-reload :noop} to prevent auto-restart on ns recompilation, or ^{:on-reload :stop} to stop on recompilation.
defines a state (a.k.a. a stateful component). restarts on recompilation. pass ^{:on-reload :noop} to prevent auto-restart on ns recompilation, or ^{:on-reload :stop} to stop on recompilation.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close