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

Pseudo classes missing from extracted CSS? #18

Open
davidhund opened this issue Jul 13, 2017 · 2 comments
Open

Pseudo classes missing from extracted CSS? #18

davidhund opened this issue Jul 13, 2017 · 2 comments

Comments

@davidhund
Copy link

I noticed extractStyles and inlineStyles does not produce any pseudo classes. E.g. a:hover was left out.

I realize this is all not usus specific (but CSS Coverage) but I was wondering why. Also: for critical styles I would expect these to be included.

@gajus
Copy link
Owner

gajus commented Jul 13, 2017

I realize this is all not usus specific (but CSS Coverage) but I was wondering why. Also: for critical styles I would expect these to be included.

This is definitely doable.

The reason it is not included is because browser never needed to use them. To make it include these styles, I would need to instruct Chrome to trigger "hover" for all elements in the DOM as part of the page loading.

This would be a separate option.

@davidhund
Copy link
Author

I'm not sure if it's 'critical' but it could surely cause some a11y issues on slow loading pages.

PS: I can understand now why they're not included since they're all user-initiated state changes. Thanks!

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

No branches or pull requests

2 participants