Nice to see that the vast majority of my website is loaded from my CDN. At this point, the caching is so good that it's practically a static site.
Also really interesting that only 1% of my site is actual HTML! That's surprising.
I love how my site looks with the fonts, but my goodness, with them being 85% of the total content, maybe I need to rethink...
Then again, the entire site is pretty quick (~400ms), so maybe I should just leave it. 🙂
@kev Very nice! I wish I could use my own CDN for airikr.me 😅 But that day will come.
@edgren Oh it's not my own CDN, like a self-hosted one. I use Bunny CDN.
@kev Oh. Alright 😃
@kev You may reconsider Fira Sans (or subset it to make it lighter): it’s the heavy one, used for titles only.
@meduz Yeah I know but it's soooooo nice!
@kev Then you’re next step is to subset it: https://www.fontsquirrel.com/tools/webfont-generator ; they also have a Latin only build that is 10% the payload of the full set: https://github.com/bBoxType/FiraSans#versionbuild-4203-sans-only
@meduz I used the Font Squirrel tool create the fonts I have. I didn't know there was a Latin only version though. I'll definitely be testing that on my staging site. Thanks!
@meduz urgh the repo containing the Latin only fonts has been deleted. :(
@kev 400ms is fast for your test bed. Please think to lower end readers.
@xdej that's a difficult thing to test for, since I don't have a slow connection, like dial up.
I haven't had any complaints about performance, so I would assume it's ok.
Other sites are MUCH slower on the test sites, so I would assume that speed is all relative, so even though my site will obviously be slower for people with poor connections, it's still a lot faster than most sites for them.
All major browsers have the ability to to throttle the connection and emulate bad connection situations.
You're already ahead of the curve as you're thinking about this issue and measuring it instead just assuming that it's fine.
If possible, you should fix that one fat asset that's the bottleneck, and it sounds like other posters have given excellent advice here. However, if doing so starts to sop up lots of time, it probably is okay. Your user might even have the font cached already if it's common.
Try this on a Dial-Up or 2G connection. ^^
Fosstodon is an English speaking Mastodon instance that is open to anyone who is interested in technology; particularly free & open source software.