-
Notifications
You must be signed in to change notification settings - Fork 28
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
Clarify invisible text #29
Comments
We might just have to leave it vague. We should probably spec that FP & FCP should behave the same with respect to invisible text though? |
@npm1 what is our behavior today in Chrome? |
The following is exposed in Chrome:
|
Sorry, I meant.. How does Chrome react in response to invisible text? E.g. if I create page with nothing but text on it and a webfont that takes forever to load, what would FP / FCP tell me today? |
I think the spec says that even First Contentful Paint "includes text with pending webfonts" (but I haven't confirmed Chrome's behavior). |
It seems Chrome triggers FP and FCP on invisible text: |
Next step: find a list of cases where we run into whitespaces causing these metrics to fire early. |
I think this will be fixed with #66 |
Can we close this? @npm1 |
The Paint Timing API says that a paint occurs when the browser has rendered pixels to the screen. Invisible text and whitespaces technically do not cause pixels to be rendered in the screen, but the text can still be highlighted or searched and this would probably cause pixels to be rendered in the screen. It's also not super clear to me how easy it is for browsers to keep track of all invisible text and differentiate it with visible text. The spec should probably clarify whether this kind of text triggers a First Paint and/or a First Contentful Paint. Also, explicit tests should be added to test the behavior when only this kind of text is rendered in a frame.
@tdresser @spanicker let's first agree on what should happen and then I'll send PRs and tests?
The text was updated successfully, but these errors were encountered: