Skip to content
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

Issue extending selectors nested using "&" #3084

Closed
joshlasdin opened this issue Jul 8, 2017 · 2 comments
Closed

Issue extending selectors nested using "&" #3084

joshlasdin opened this issue Jul 8, 2017 · 2 comments

Comments

@joshlasdin
Copy link

joshlasdin commented Jul 8, 2017

I often write "nested" selectors using the & to reference the base piece of the class (similar to BEM, SUIT, etc):

.testComponent {
  &-child { ... }
  &--variant { ... }
}

However, I've found that when I attempt to extend one of these "nested" selectors, it fails to compute correctly:

.foobar:extend(.testComponent-child) {}

I'm not sure if this is expected of the language, or not, but wanted to toss it out there to see if I should be doing something differently. I'd like to be able to extend these selectors without removing the convenience that "&" gives me when defining the selectors.

I've put together a simple CodePen showing the issue here: https://codepen.io/joshlasdin/pen/GEYmzV

Thanks!

@seven-phases-max
Copy link
Member

See #2200.

@seven-phases-max
Copy link
Member

Closing as duplicate of #2200.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants