Last active
November 2, 2018 19:49
-
-
Save GaryJones/33139136fedc578ebd79 to your computer and use it in GitHub Desktop.
[Replaced] CSSComb file for WP core.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
See https://github.com/cedaro/grunt-wp-css/blob/develop/tasks/config/default.json |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Configuration Options are detailed at https://github.com/csscomb/csscomb.js/blob/master/doc/options.md
Current WP CSS coding standards for property ordering are outlined at http://make.wordpress.org/core/handbook/coding-standards/css/#property-ordering . These are too generic, so using an automated tool (via grunt, editor plugin, website (once re-done)) with unambiguous prescriptive list of individual properties is better.
exclude
andverbose
are optional and just here to show they exist. Main focus here is the sort order. Properties are broken up into Display, Positioning, Box Model, Colors and Typography, and Other as per CS. All given in one array, so no clear linespaces will appear in the sorted output.$variable
and$include
cover sorting with both Sass and LESS variables and mixins / extend, so suitable for all projects outside of core too.https://core.trac.wordpress.org/ticket/20570#comment:32
https://core.trac.wordpress.org/ticket/22097
Feedback welcome.