5 ms·
Opinions are my own. I don't think this is recommended to use internally at Google because it's not supported on Safari.
by thanhhaimai 5y ago
Opinions are my own.
I don't think this is recommended to use internally at Google because it's not supported on Safari.
- kevingadd 5y agoEven if they can't use contain, this is a self-inflicted problem - if you look at the screenshot, other elements + a drop shadow overlap the content list, which means it can't trivially be efficiently scrolled by a compositor, and it's quite reasonable for the browser to assume that it can affect layout. If it were a properly isolated box in the page without overlap with overflow turned on I bet this would have already worked properly.
- Twirrim 5y agoBut the fancy graphics! Got to have the fancy graphics! Form > Function.
- pcwalton 5y agoI don't think this is a reasonable assumption for the browser at all. It's 2021; WebRender has proved that a better design is possible.
- kevingadd 5y agoSure, but are Chrome and Safari going to do a WebRender-style renderer anytime soon? WebRender is great but in practice it affects at most (generously) 20% of the web audience. Optimize for the browser you have, or maybe the browser coming next year, not the one your customers will have in 5 years.
- nicoburns 5y agoThat seems like a bizarre reason not to use it, given that it's strictly a performance optimisation, and browsers will simply ignore CSS rules they don't understand.
- FastEatSlow 5y agoI imagine that it could cause accusations from Apple that Google is trying to take their customers out of the ecosystem, putting a nice cash flow at risk.
- johncena33 5y agoIt doesn't have to be Apple. There would be dozens of articles on HN front news and HN crowd would complain year after years about it.
- xmprt 5y agoIt's a bad argument because if someone else makes a better product then they deserve to get more users. Nothing's stopping Apple from implementing those optimizations into Safari. That's the whole reason we have competition. If the government is going to make it so that improving your product makes you liable to lawsuits then no one would ever improve anything.
- FastEatSlow 5y agoIt's not the government dictating the lawsuits, I was referencing the deal between Apple and Google to have Google as the default search engine on Safari.
- wnevets 5y agoHasn't Google been accused of doing exactly that with YouTube and FireFox?
- sebazzz 5y agoIt causes a new stacking context which has significant impact on how everything is rendered and things like Z-index behave. This can cause head-scratching issues and differences which aren't obvious at first sight.