Fork me on GitHub
#cider
<
2023-02-26
>
hifumi12313:02:05

Does CIDER support dynamic indentation in ClojureScript files? For some reason this example is failing:

(defn a-fn
  "A docstring"
  [& args]
  {:style/indent 1}
  args)
But I can clearly see :style/indent 1 when I run (meta #'a-fn)

bozhidar16:02:47

This data is relayed via the track-state middleware, which if I recall correctly was not Clojure specific. I might be mistaken, though. I haven’t touched this code in ages and I almost never do anything with ClojureScript.

bozhidar16:02:08

Basically track-state passes some data to clojure-mode, so it can rebuild its indentation table.

👍 1
bozhidar16:02:05

FYI - Today I opted to make a small change that makes printing to the REPL a bit worse in a particular edge case (your REPL prompt is right at the top of the REPL window), but 10x faster https://github.com/clojure-emacs/cider/commit/2e213f92d7bd84da9bf3826a42edb43a4e2fe7b3

🙌 2