Clojurescript Swap! and multiple union
An attempt to make the code more attractive.
In Clojurescript, I have the following:
(swap! app-state assoc-in [:lastresults] [])
(swap! app-state assoc-in [:error] false)
(swap! app-state assoc-in [:computing] true)
Sometimes more. Any idea on how to turn this into cleaner multitasking.
I am looking at something like:
(swap! app-state assoc-in
[:lastresults] []
[:error] false
[:computing] true)
+3
source to share