why does ktfmt change the formatting of this kdoc:...
# ktfmt
c
why does ktfmt change the formatting of this kdoc:
Copy code
/**
- * Lifecycle functions for resources that are used by tests.
- * This is a separate interface because it is available in the ContextDSL and in the TestDSL
+ * Lifecycle functions for resources that are used by tests. This is a separate interface because it
+ * is available in the ContextDSL and in the TestDSL
  */
I think the first version is more readable because each sentence has its own line.
c
I think ktfmt uses tor norbyes kdoc formatter https://github.com/tnorbye/kdoc-formatter
👍 1
i suppose you can ask the question right there in its issue tracker
by the looks of it. it does format it the way i would assume it should be formatted IMO.
c
thanks! maybe you are right that its better that way. I just thought that if it takes 2 lines anyway the two sentences could be on separate lines.
c
Maybe if you put an extra blank line in between them then it wouldn't reformat?
👍 1
c
btw it seems ktfmt really uses kdoc-formatter but by copying the source code instead of as a dependency.
and you are right, adding an extra blank line will stop the reformatting.
c
ooh. interesting!