|
|
|
|
|
by alwillis
724 days ago
|
|
> While I admire Gwern's work a lot, I often find his website is trying to do so much that my browser will really struggle. As a web developer, I often look at the HTML and CSS of interesting websites… I gotta say, I've never seen anything quite like https://gwern.net. It's an impressive looking site IMHO; but pretty much everything he's done is very user hostile and wasteful of the user's resources, like downloading 14 fonts. He's doing everything you're not supposed to do if you care about your users or performance in general. Every page is pretty much like this. From cssstats.com: Rules: 1,484 Selectors: 1,757 Declarations: 3,914 Properties: 243 Total Selectors by Type Selectors are the part of a CSS ruleset that describes what elements in a document the rule will match. ID: 534 Class: 1,516 Pseudo Class: 296 Pseudo Element: 382 It just goes on and on like this. |
|
Similarly for those other numbers about selectors or classes. How much of a performance burden are those, really? Not the numbers punched out by some cargo cult calculator tool - what is the actual impact?
(I would try to compare cssstats.com's numbers for Gwern.net to sites we can all agree are "very user hostile and wasteful of the user's resources", like Medium.com or Substack... except it breaks and won't even report numbers.)
> It's an impressive looking site IMHO; but pretty much everything he's done is very user hostile and wasteful of the user's resources,
That seems like an extreme take. 'Pretty much everything'? There's no feature you like or find useful? It's all a waste? Your non-wasteful user-friendly version of gwern.net just throws out everything like the dropcaps, the code folding, the popups, the transclusions, the sidenotes, the backlinks, the link-icons...?
If that's not what you mean, can you point to a website which comes anywhere near Gwern.net in terms of supporting reading long, complex, heavily hyperlinked & annotated documents, and clearly outperforms it browser-wise?
> like downloading 14 fonts.
I'm not sure what page you are looking at, but what are these '14 fonts', exactly? It sounds like you're counting every font file without looking at them at all, and you are including, eg, the dropcaps which are subset to 1 letter per font file and so are efficiently only ~1-10kb each, or the link-icon font file, which is like 5kb compressed and saves requesting a bunch of SVG icon files, or the Quivira fallback (to avoid box Unicode garbage) which shouldn't be used in most pages but if it is, that's fine, because it's all of 3.5kb. Surely any performance woes do not come from downloading 5kb to draw a fancy 'A' at the beginning of the article, and is worth it for such a signature bit of visual style...
Even the regular font files are subsetted to save space. (I wouldn't be surprised if there are a lot of websites with just '1 font' which weigh more than those '14'.) So the font files do not seem like they are 'wasteful' to me.