(defn
refresh-console-content!
[content state console-start-num clj?]
(set!
(.-innerHTML content)
(if
clj?
(let
[pre-text
(subs (:text state) 0 console-start-num)
post-text
(subs (:text state) console-start-num)]
(str (hs/escape-html-str pre-text) (hs/code->html post-text)))
(hs/escape-html-str (:text state))))
state)