You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If you run this code against the selector-no-union-class-name test it will crash the entire process.
I did some research and found out that the reason is that the parent of button:hover & { is @include demo() { and therefore there is no selector property for the parent in this line:
The good news is that the selector is in the parent of the parent:
So probably we could just iterate over the parents until we find the closest parent with a selector` property.
If none can be found we just skip the test.
What do you think?
The text was updated successfully, but these errors were encountered:
Reproduction css example:
If you run this code against the
selector-no-union-class-name
test it will crash the entire process.I did some research and found out that the reason is that the parent of
button:hover & {
is@include demo() {
and therefore there is noselector
property for the parent in this line:https://github.com/kristerkari/stylelint-scss/blob/147b44cf10725fbf7b08a33885a6f7b7b8df4bb9/src/rules/selector-no-union-class-name/index.js#L38
The good news is that the
selector
is in theparent
of theparent
:So probably we could just iterate over the parents until we find the closest
parent
with a selector` property.If none can be found we just skip the test.
What do you think?
The text was updated successfully, but these errors were encountered: