vim

walterl 2025-03-14T13:18:10.781039Z

What do you guys do to toggle forms between single- and multi-line formats? I.e. toggling between (assoc m :key "value") and

(assoc
  m
  :key
  "value")

walterl 2025-03-14T13:19:13.714639Z

https://github.com/ckolkey/ts-node-action's toggle_multiline does this in other languages, so thinking of contributing Clojure support there, but this feels like it should already exist in some of the common Clojure tools.

practicalli-johnny 2025-03-14T15:14:56.678079Z

Personally I don't see a need as J will join the lines of an expression (and Return will split the expression). If people do find this useful then Clojure LSP would seem an appropriate place, as one of its code actions.

walterl 2025-03-14T22:40:05.170669Z

vibJ is OK, but manually splitting forms by manually adding newlines after each form element just doesn't feel like the structural, form-level editing that's so great in Clojure.

James Amberger 2025-03-15T02:46:46.695219Z

there’s https://github.com/AndrewRadev/splitjoin.vim

❤️ 1
👆 1