3 ms·
Previews only use the HMTL head - to get OG metadata - and usually an image. Never thought about this before. One of my sites is (a single-page application) 4
by martinclayton 2y ago
Previews only use the HMTL head - to get OG metadata - and usually an image.
Never thought about this before. One of my sites is (a single-page application) 45k HTML and 40k image. Hence about 50% of what is served for previews is wasted.
It would be nice if there was a way to recognise an "only html head needed" type of request. Don't think there is?
- jakebasile 2y agoThat'd be the HTTP HEAD verb. https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/HEAD https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/HE...
- abeyer 2y agoNope, unless things have changed since I last dealt with it, Open Graph metadata is not considered "http-equiv" so does _not_ get served as an http header, only as a meta tag in the html header... so the HEAD verb won't get them for you.
- jakebasile 2y agoAh yeah, that's just the HTTP headers, not the HTML head. Whoops!