3 ms·
I use Calibre for font subsetting, usually for use in ebooks, but I've used it for a website as well. The only gotcha I've found is that Calibre doesn't recogni
by efreak 4y ago
I use Calibre for font subsetting, usually for use in ebooks, but I've used it for a website as well. The only gotcha I've found is that Calibre doesn't recognize css content attributes (`div.icon{content:"source:"}`), and that font names need to be correct. This is pretty trivial to get around, and generally only needs to be done once.
I've never used webpack or any other bundler on any personal website I've written, nor have I ever used react or other heavy frameworks (I used jQuery when I was in school). Perhaps these are useful on larger websites, but I prefer to avoid scripts in general, with the sole exception being scripts that parse a data source to generate a page client-side (most pages on my system are static, so I don't even have php or such installed). To me, automation means I make changes to the html on my server and reload the page.
- WorldMaker 4y agoSVGs are still often better subsetted raw ("unbundled") in that case both for local development and on HTTP/2+ servers. Things are slowly moving back away from bundlers/bundles which were mostly about getting the most out of HTTP/1.x tradeoffs most of which either no longer apply (because changes in browser caching rules for privacy reasons) or are mostly obsolete concerns (with HTTP/2+). You aren't going to get easier subsetting in a modern browser than a folder full of SVGs and the browser only pulling the URLs it needs as it needs them rather than an entire bloated icon font format all at once up front. No need to double check that Calibre has got the right font subset from your CSS or to open Calibre at all, just upload the folder of SVGs and let the browser "subset" it, in the classic ways of HTML going back to its origins. Even less "automation" than Calibre.