Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Follow-up to #2865971: Use stylelint as opposed to csslint in core. Configure the rule-empty-line-before
to be consistent with https://www.drupal.org/docs/develop/standards/css/css-coding-standards
Proposed resolution
Brief instructions on running stylelint - you'll need npm...
All the commands below take place in DRUPAL_ROOT/core
To install stylelint
npm install
This will install Drupal 8's npm dependencies of which stylelint is one.
To run it on all core css files. Apply this issue's patch and do the following command from DRUPAL_ROOT/core
npm run lint:css
Remaining tasks
User interface changes
None
API changes
None
Comment | File | Size | Author |
---|---|---|---|
#5 | 2866821-5.patch | 440 KB | joelpittet |
Comments
Comment #2
alexpottComment #3
alexpottComment #5
joelpittetHere's using the defaults. I'm for this patch but I think it undoes some grouping people have done to keep similar selectors together. Anyways up for discussion.
Comment #7
joelpittetComment #9
joelpittetI'll set this to NW for discussion on if this change is worth it?
Comment #19
longwaveFor me this is won't fix; from https://www.drupal.org/docs/develop/standards/css/css-formatting-guidelines