I thought images with a 0.01 bit per pixel ratio should not be considered for #LCP in Chromium, but I have a live example (I can't disclose) where it does. 🤔

I thought the threshold was 0.05, based on https://chromium.googlesource.com/chromium/src/+/refs/heads/main/docs/speed/metrics_changelog/2023_04_lcp.md

Where can I find current definition of LCP as it is implemented in browsers?

#webperf

Chrome Speed - Largest Contentful Paint change in Chrome 112 to ignore low-entropy images

@nhoizey I think the note here is as specific as the spec gets. https://w3c.github.io/largest-contentful-paint/#largest-contentful-paint-candidate. Poking around, I wasn't able to find any WPTs, and I think the fuzziness is intentional, with the limits intended to be UA-defined.

Not sure if Chrome has done any more documentation here. I'll bug Barry Pollard over on Bluesky!

Largest Contentful Paint

@eeeps thanks you!

Here it says “candidate’s element’s opacity is > 0”, but the image I found considered to be the LCP is a transparent SVG containing multiple of these:

<g stroke="none" fill="none" fill-opacity="0"><rect x="0" y="0" width="1000" height="1000"></rect></g>

So I'm pretty sure its opacity is not > 0… 🤷‍♂️

Is @tunetheweb not here anymore? 🥺

@nhoizey @eeeps Occasionally here when I get tagged in things. but still not loving Mastodon UX 🙂

That sounds like this LCP hack:
https://issues.chromium.org/issues/326876094

The question is how much to spend chasing down these hacks versus spending time on things that are actually useful to people! Personally I'd rather to the latter. There's always gonna be someway to fool a heuristic. And if people wanna trick themselves then who are we to say they're being stupid and blinding themselves for negligible gain 🤷‍♂️

Chromium

@tunetheweb happy to see you there! ☺️ I'll try not to ping you too much… 😅

This is exactly the same hack indeed, but with an external SVG.

So at least it's a known issue, I'll follow this issue, thanks. 🙏

@eeeps

@nhoizey @eeeps I reran the stats. 186 sites out of 15,408,501 are using this hack. Or 0.000012% of the web. That's up from 84 sites 2 years ago, but still not a priority to address IMHO.

If you see sites using it, and know devs working there, then suggest you give them a poke to find out why. A bad plugin they weren't aware of? Or intentional cause they don't understand? Or intentional cause they do understand and just wanna get someone off their back for something they don't care about?

@nhoizey @eeeps A bit more (1024 sites) if you include that other variant mentioned in the bug.

Looks like Interflora.fr and Interflora.it are still using this hack across their sites (but with an external, self-hosted SVG adn we don't store images so more difficult to measure) if anyone knows anyone working there to name and shame them to!

@tunetheweb I've seen your update to the issue 👍

The SVG I found is external, loaded with both `<link rel="preload"…>` and `<img fetchpriority="high" …>`.

I'm pretty sure it's an intentional hack to game the LCP algorithm.

I'll try to contact someone I know who should know why it's there.

@eeeps