Repository navigation
Add grouping option to the sorted_imports rule - #4935
Conversation
a930d40 to
ce49660
Compare
Generated by 🚫 Danger |
ce49660 to
47ee139
Compare
grouping option to the sorted_imports rule
|
So It also sorts imports slightly differently as well - #4810 Not sure what the right answer is here, but it's a shame that we can't have some compatibility so that people can use both together, without the linters fighting over which is the correct order. |
|
@mildm8nnered There’s definitely room for different import sort strategies. I’m open to changing the naming to allow for adding a swift-format compatible strategy down the line. Maybe |
I think I wouldn't worry about it too much for now. I don't think that many people actually run |
SimplyDanny
left a comment
There was a problem hiding this comment.
Thank you for the contribution! I have a few remarks.
The most important point is that attributes do not necessarily have to stand on the same line like the import statement.
2c22a3c to
f0c35e8
Compare
65d7929 to
49017df
Compare
Co-authored-by: Danny Mösch <[email protected]>
dae615b to
47ba61d
Compare
SimplyDanny
left a comment
There was a problem hiding this comment.
Thank you for your work and your patience!
I've just rebased your branch since there were some conflicts caused by recent refactorings on main.
|
Thanks @SimplyDanny! |
Adds a
groupingoption to thesorted_importrule. With this configuration:It puts all the
@testableimports at the top of the import groups.