cljfmt icon indicating copy to clipboard operation
cljfmt copied to clipboard

Default formatting for wrapped imports pulls left instead of aligning with previous classes

Open a613 opened this issue 7 years ago • 2 comments
trafficstars

Imagine a long, unwrapped list of imports:

(:import [java.io BufferedReader BufferedWriter ByteArrayInputStream ByteArrayOutputStream])

The Clojure convention is to indent these wrapped lines so that they align with previous classes:

(:import [java.io BufferedReader BufferedWriter ByteArrayInputStream
                  ByteArrayOutputStream])

And that's how I have it formatted in my project. But cljfmt re-formats like this:

(:import [java.io BufferedReader BufferedWriter ByteArrayInputStream
          ByteArrayOutputStream])

How would I configure cljfmt to line these classes up, and shouldn't that be cljfmt's default behaviour?

a613 avatar Mar 06 '18 20:03 a613

Poke

a613 avatar Mar 29 '18 20:03 a613

cljfmt doesn't currently support that type of indentation.

weavejester avatar Mar 29 '18 20:03 weavejester