Re: [csswg-drafts] [css-conditional] [css-contain] `srcset` and `sizes` interaction with container queries (#5889)

*belatedly catching up...*

I agree with @eeeps about the inherent tradeoff here, about the ability to go with nested `sizes` and about the inability of humans to make sense of that.

I similarly agree with @chrishtr that for anything outside any initial viewport, lazy loading it has no performance cost and should be encouraged.

But, that leaves us with "images inside a container query that are in an initial viewport of some form factors".
What would be our developer advice in that case?
* The initial layout is fast if the relevant CSS is fast to arrive. Can we simply advise developers to make sure the layout structure of their initial viewport is laid out by inline styles? Is that a reasonable thing to ask?
* While humans won't be able to generate nested `sizes` attributes, tools might. *<insert "the tools will save us" meme here>* Is that a reasonable path?
* We tell developers to avoid Container Queries in the initial viewport? (even if we would, they are not likely to listen)
* We live with slower LCPs for developer convenience? (Not a fan of this option, but might be interesting to quantify the damage IRL)
* A better option that has alluded us for the last 6 years?

I'm not sure what the answer is, but seems like we need one.



-- 
GitHub Notification of comment by yoavweiss
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/5889#issuecomment-779750709 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 16 February 2021 10:40:56 UTC