4 ms·
Jesus, why bother we a lean site with that mindset. If it truly is a must make it a small (self-hosted) png.
by tjoff 7y ago
Jesus, why bother we a lean site with that mindset.
If it truly is a must make it a small (self-hosted) png.
- e12e 7y agoEh, then it's no longer text? Fwiw I don't really think a one-time large font download is much of a problem - considering that improved typography is a very good way to improve how a site looks. And unlike your png - the text will display without the custom font. Fall-back fonts are only really a problem with icon font sets.
- tjoff 7y agoIt will read just fine. But no, I would not recommend it. But much rather that than a multi-megabyte one-liner. One time. Per site. On slow and/or expensive mobile connection? The png will also display without the custom font...
- e12e 7y agoPng has poor screen reader support, though it can be amended via an alt tag, I suppose. [ed: but breaks copy and paste, which might be bad for an about page listing address and contact information - personally I'd much prefer fallback font to a png]. It's a shame there are no "bandwidth" queries in css, like there are @media queries - the client should be able to say - just content and essential downloads, please.
- tunetheweb 7y agoThey’ve been proposed!: https://drafts.csswg.org/mediaqueries-5/#prefers-reduced-data https://drafts.csswg.org/mediaqueries-5/#prefers-reduced-dat... You can already do this with JavaScript now: https://developer.mozilla.org/en-US/docs/Web/API/NetworkInformation https://developer.mozilla.org/en-US/docs/Web/API/NetworkInfo... though as you can see from the bottom of that link, Browser support is limited at the moment (and experimental so may even be removed/changed!).
- Symbiote 7y agoOr better, just use a system font. Anyone who can read Japanese will have a suitable font installed.
- XelNika 7y agoLol, his about page pulls a 1.42 MB font to display eleven characters in a light font weight instead of my system font. On a page that would otherwise be ~30 KB.