Liking cljdoc? Tell your friends :D

state-flow.state


error-contextclj

Same as state monad context, but short circuits if error happens, place error in return value

Same as state monad context, but short circuits if error happens, place error in return value
raw docstring

evalclj


execclj


getclj

(get)

Returns the equivalent of (fn [state] [state, state])

Returns the equivalent of (fn [state] [state, state])
raw docstring

getsclj

(gets f)

modifyclj

(modify f)

Returns the equivalent of (fn [state] [state, (swap! state f)])

Returns the equivalent of (fn [state] [state, (swap! state f)])
raw docstring

putclj

(put new-state)

Returns the equivalent of (fn [state] [state, new-state])

Returns the equivalent of (fn [state] [state, new-state])
raw docstring

returnclj

(return v)

Returns the equivalent of (fn [state] [v, state])

Returns the equivalent of (fn [state] [v, state])
raw docstring

runclj


state?clj


swapcljdeprecated

(swap f)

DEPRECATED: use modify

DEPRECATED: use modify
raw docstring

wrap-fnclj

(wrap-fn my-fn)

Wraps a (possibly side-effecting) function to a state monad

Wraps a (possibly side-effecting) function to a state monad
raw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close