css minification

Sebastiaan Koppe via Digitalmars-d digitalmars-d at puremagic.com
Sun Jan 18 01:01:23 PST 2015


On Sunday, 18 January 2015 at 07:42:10 UTC, Andrei Alexandrescu 
wrote:
> On 1/17/15 11:23 PM, Sebastiaan Koppe wrote:
>> On Saturday, 17 January 2015 at 20:52:28 UTC, Andrei 
>> Alexandrescu
>> wrote:
>>>
>>> Our webmaster got back. He said compression is more CPU work 
>>> and on a
>>> fat pipe (which we do have) that may make things actually 
>>> worse. Also,
>>> how would this work if we switch to vibe.d? -- Andrei
>>
>> If you do not have spare horsepower for compression, how will 
>> you
>> handle twice the load?
>
> Not quite getting the logic there. -- Andrei
It is unrelated to my point about compression. The reasoning is 
as follows: if you are maxed out on resources, you will have 
problems when the site gets more visitors.

Compression can still help there. If the file is compressed the 
server needs to send less bytes, and can close the connection 
quicker. Pre-compression instead of doing on-demand, like Adam 
Ruppe said, will optimize it even more.

Btw. I build the dlang.org site on my computer but the <script> 
links have an %0 in the src attribute. Then 5 min later I saw the 
same on dlang.org

Funny thing is, all stuff is still functioning. Affirming my 
hunch that you can remove a lot of the js stuff.

The site now loads in 124kb. Whoever put that %0 there, you just 
cut down the site from 300kb to 124kb. Nice Job!


More information about the Digitalmars-d mailing list