New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix overrides.extends
order when including same rules
#6658
Comments
@kuoruan Thanks for the report with the template. As you said, it seems But, at the same time, this seems an edge case. Could you tell us your specific situation when you found a behavior, please? If possible, it would be so appreciated if you could provide a minimal repository for the reproduction. |
@kuoruan Thanks for sharing the demo. I understand your pain. We expect $ npx stylelint --print-config .stylelintrc.js | grep -A3 'selector-class-pattern'
"selector-class-pattern": [
"^([a-z][a-z0-9]*)((-|--|__)[a-z0-9]+)*$",
{}
], $ npx stylelint src/main.scss
src/main.scss
1:1 ✖ Expected class selector ".c__a-b" to be kebab-case selector-class-pattern
1 problem (1 error, 0 warnings) I've labeled the issue as ready to implement. Please consider contributing if you have time. There are steps on how to fix a bug in a rule in the Developer guide. |
overrides.extends
not work as expectoverrides.extends
order
overrides.extends
orderoverrides.extends
order when including same rules
What steps are needed to reproduce the bug?
#6380 changes the behaviour of
overrides.extends
@jasikparkIn following config file,
./a
is the last item, it should in the last of the merge array.But in the pull request
stylelint/lib/augmentConfig.js
Lines 303 to 305 in 4daef24
./a
in firstextends
is used.What Stylelint configuration is needed to reproduce the bug?
How did you run Stylelint?
none
Which version of Stylelint are you using?
15.1.0
What did you expect to happen?
overrides.extends
work as expectWhat actually happened?
see previous
Does the bug relate to non-standard syntax?
No response
Proposal to fix the bug
No response
The text was updated successfully, but these errors were encountered: