User Details
- User Since
- Jan 4 2022, 12:45 PM (19 w, 15 h)
Jan 7 2022
The current behavior when ColumnLimit: 0 and JavaScriptWrapImports: false formats this:
import {aaa} from "abc"; import {aaa, bbb, ccc} from "def"; import {aaa, bbb} from "defghi"; import {aaa, looooooooooooooooooooong, ccc,} from "ghi"; import { aaa, ccc, bbb } from "jkl";
Jan 6 2022
My guess that ColumnLimit: 0 is rarely used for JS is based on the objective fact that JS import formatting is (IMO very) buggy with the column limit set that way, and it took several years for us to hear a bug report about it. And "we should not make assumptions about what people will want" applies just as well to the proposal of force-wrapping at >= 2 imports.
Thanks for the feedback. Two things:
Jan 5 2022
That's what happens when you hit the column limit, when there is a column
limit. But do we really want every one-symbol import to wrap to 3 lines
when ColumnLimit: 0? Slash to force the user to unwrap every import, even
20-symbol 300-column imports, to a single line?
Thanks all for the reviews. I've updated the patch and added responses to your comments.
- Move source code for option documentation to Format.h, from which the RST is autogenerated.
- Clean up tests in response to review feedback.