eslint-config icon indicating copy to clipboard operation
eslint-config copied to clipboard

Consider adding some tool to sort CSS properties.

Open stefanobartoletti opened this issue 1 year ago • 0 comments

Clear and concise description of the problem

First of all thanks for integrating the ability to lint also CSS files in the latest versions.

I think it would be a nice thing to have some sort of preset for ordering CSS properties, in order to have a more logical disposition and also help with git merges.

In my current config based on stylelint I am using https://github.com/stormwarning/stylelint-config-recess-order and it does the job very nicely.

Suggested solution

Since at the moment you have included Prettier to lint CSS, you can consider this

https://github.com/Siilwyn/prettier-plugin-css-order

which in turn seems to be based on the more generic PostCSS

https://github.com/Siilwyn/css-declaration-sorter

If in the future you will consider dropping Prettier for good, another solution may need to be found, but at the moment this seems to be a nice solution

Alternative

No response

Additional context

No response

Validations

  • [X] Follow our Code of Conduct
  • [X] Read the Contributing Guide.
  • [X] Check that there isn't already an issue that request the same feature to avoid creating a duplicate.

stefanobartoletti avatar Dec 11 '23 14:12 stefanobartoletti