Exploring Large HTML Documents on the Web

https://calendar.perfplanet.com/2025/exploring-large-html-documents-on-the-web/

Comments

ayarosDec 2, 2025, 11:41 PM
I've used embedded SVG images in CSS encoded as base64, and I'm not ashamed. In general, I really wish I could apply page styles and CSS3 variables to the internal CSS of SVG files. I'm sure there's a good reason why this context isn't shared, but it would be cool and useful to dynamically change the style of SVG files.

If I'm hand coding a page or writing a stylesheet, it's convenient to be able to embed things. Often, I'll embed a style tag until it grows large enough to be worthy of its own file. The same goes for scripts; it's useful to have the option if you're quickly prototyping something.

beezlewaxDec 3, 2025, 6:33 AM
You CAN target ids in svgs though? And apply fill etc by css
ayarosDec 3, 2025, 9:38 PM
Not in all situations. I'm pretty sure I can't do it when the SVG file is applied as a background image.
1718627440Dec 4, 2025, 8:13 PM
Yeah of course, you must embed it as content. So use <object> or <svg> directly.
qingcharlesDec 2, 2025, 11:38 PM
I don't know if I remember seeing this site before -- it appears to be an advent calendar of web performance tips? Good stuff.
ssttooDec 3, 2025, 8:07 AM
Yup, it’s web performance advent calendar in its 17th edition. I’m the maintainer, AMA. Also still accepting contributions for this year.