cursive-ide / cursive

Cursive: The IDE for beautiful Clojure code
579 stars 7 forks source link

Allow custom folding per form #2042

Open cursive-ide opened 6 years ago

cursive-ide commented 6 years ago

It would be useful to be able to specify for a particular form how it should be folded. For example, a let could be folded to just show the variables it defines, defn could show the available arities and parameters and so on.

It would also be desirable for forms to be able to identify their body forms, so that these could be folded if they were data structures, e.g. a function which returns a large hiccup structure.

cursive-ide commented 4 years ago

This is required for #1079 and others.

olttwa commented 3 weeks ago

Hey @cursive-ide reached here from #1269 and other forums. Would really appreciate if there's a way to fold Maps and Vectors as Integrant, Bidi, Component configs get very bloated and it's difficult to read without capability to fold.

I tried opening a Clojure file with VS Code and it worked fine. I am guessing it simply matched based on [], {}, () brackets and not proper Clojure forms.