leo-buneev / eslint-plugin-sort-keys-fix

Fork of https://eslint.org/docs/rules/sort-keys that allows automatic fixing
95 stars 22 forks source link

feat: move above comments together with property #18

Closed pahan35 closed 4 years ago

pahan35 commented 4 years ago

Relates to #2

The difference from #2 relies on moving comment above instead of comments on the same line.

For me, it's more critical because I add comments above the properties. Also, it'll help with // eslint-disable-next-line comments

Known problems

The newline symbol from the comment remains. It should be easily fixed by prettier. I saw such policy in one of the used eslint plugins, so I hope it won't be a blocker to merge it: better remove extra new line than move comment manually