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

Support for attribute selectors #35

Closed
ostrgard opened this issue Mar 29, 2016 · 4 comments
Closed

Support for attribute selectors #35

ostrgard opened this issue Mar 29, 2016 · 4 comments

Comments

@ostrgard
Copy link

Hi!

There's currently no support for attribute selectors. I could make a small PR with support and tests for this, if you're interested, unless it's left out by design?

@xymostech
Copy link
Contributor

I think that it is left out by design. Is there a reason why you would need to be testing for selectors and couldn't just be conditionally adding more styles? I assume the attributes are being added to the element that you are styling, so you should have access to them, no?

@ostrgard
Copy link
Author

ostrgard commented Apr 3, 2016

I don't have a specific use case for this, I just saw it as a low hanging fruit to cover more of the CSS spec.

@kentcdodds
Copy link
Contributor

Yeah, from my (user) perspective, the more I use this, the more I come to realize that the idea of this library is to associate styles with specific elements (components) in an explicit way rather than the implicit nature of CSS. So there actually is no concept of selectors at all. It's all about taking styles and applying them directly to components.

This is still taking some getting used to for me, but the more I use aphrodite, the more I buy into the concept. 👍

@xymostech
Copy link
Contributor

@kentcdodds Glad you're enjoying the library!

I agree, so I'm going to close this, because we don't want to support attribute selectors.

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

3 participants