Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lint-staged.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module.exports = {
() => 'npm run prelint:js',
'node ./tools/eslint/lint-js.cjs --config eslint.config.strict.cjs',
],
'*.scss': [ 'wp-scripts lint-style' ],
'*.{scss,module.css}': [ 'wp-scripts lint-style' ],

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree with consistency with lint:css, but it has me wondering why we specify .module.css specifically rather than just .css. Apparently I was the one who added this in #72758 😄 Maybe I had it in mind as a light nudge to force source files as either .scss or .module.css and not plain .css. Some CSS files are artifacts that we maybe don't want to lint (e.g. design-tokens.css), but there's quite a few others that seem totally valid for linting:

(and more)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see @ciampo made a similar point at #79900 (comment) 😄

'package-lock.json': [ 'npm run lint:lockfile' ],
'packages/*/package.json': [ 'wp-scripts lint-pkg-json' ],
'{docs/toc.json,tools/docs/*.cjs,packages/{*/README.md,components/src/*/**/README.md,block-library/src/*/README.md}}':
Expand Down
Loading