On 05/18/2018 06:11 AM, Stuart Longland wrote:
> On 18/05/18 12:09, Ken M wrote:
>> In all honesty I wasn't thinking of the suggestion as a cautious one because 
>> of
>> bloat. I think bootstrap minified and compressed is like 20k. I mean how big 
>> is
>> the entire man page collection?
> 
> 20kB may not sound like a lot, but consider, say, the `sh` man page:
> 
> http://man.openbsd.org/sh
> 
> The man page itself (the file in /usr/share/man) is about 53kB in size.
> There are bigger man pages; some over 1MB (perltoc for example), I
> picked that one arbitrarily.
> 
> Rendered as HTML; Firefox tells me that link and all its resources is
> about 153kB.
> 
> Throwing bootstrap in there adds an extra 13% to the total page download
> size (173/153 =~ 1.13).  The only saving grace here is that the browser
> ought to be caching that shared resource, and in ordinary circumstances
> it will, but you're at the mercy of what the browser (and intermediate
> proxies) decide to cache.
> 
> If they decide to not cache: you'll be hit with that extra 20kB on each
> page view.  It doesn't sound like a lot, but it adds up.

It actually gets worse than that.
CSS is loaded synchronously, i.e., when the <link> tag is found.
This means that those extra 20 kB will be tacked on before you even see
the page content. On slower connections, this may become quite annoying.
All asynchronous options seem to require some form of JavaScript hack
(cf. https://www.filamentgroup.com/lab/async-css.html).

Reply via email to