<story><title>Minify and Gzip (2022)</title><url>https://blog.wesleyac.com/posts/minify-and-gzip</url></story><parent_chain><item><author>mschuster91</author><text>&amp;gt; Especially things like removing as much whitespace as possible or replacing true&amp;#x2F;false with !0&amp;#x2F;!1 just don&amp;#x27;t really save a lot of space.&lt;p&gt;At the scale of Wikipedia (~10 billion pageviews a month), even a single byte saving can mean terabytes worth of bandwidth saved.</text></item><item><author>arp242</author><text>A few years ago I did some measurements of popular projects (Wikipedia, WordPress, default React, jQuery, few things like that) comparing minify, minify+gzip, and just gzip, and found found that most minification beyond &amp;quot;removing comments&amp;quot; gives very little benefit even for poor 2G connections.&lt;p&gt;Especially things like removing as much whitespace as possible or replacing true&amp;#x2F;false with !0&amp;#x2F;!1 just don&amp;#x27;t really save a lot of space. The only two I found to make a significant difference were removing comments, and shortening identifiers (and usually with most of the savings being in &amp;quot;removing comments&amp;quot;, depending on the amount of comments and code style).</text></item></parent_chain><comment><author>foobarbecue</author><text>I see this type of reasoning a lot and it feels like it should have its own named fallacy. A tiny percent savings on a huge cost is a moderately big number, yes.&lt;p&gt;The problem here is that you&amp;#x27;ve switched from proportional thinking to arithmetic thinking in the middle of the thought.&lt;p&gt;In most cases, if you started with proportional thinking, you should stick to it.&lt;p&gt;Example of the fallacy: 0.1% of my salary goes to avocado toast, which might not seem that much, but over ten years, that&amp;#x27;s a thousand dollars!&lt;p&gt;The fallacy here lies in the fact that a thousand dollars is insignificant over 10 years, but the statement makes it feel significant by switching from proportional to absolute.&lt;p&gt;&amp;quot;The avocado toast fallacy&amp;quot;?</text></comment>
<story><title>Minify and Gzip (2022)</title><url>https://blog.wesleyac.com/posts/minify-and-gzip</url></story><parent_chain><item><author>mschuster91</author><text>&amp;gt; Especially things like removing as much whitespace as possible or replacing true&amp;#x2F;false with !0&amp;#x2F;!1 just don&amp;#x27;t really save a lot of space.&lt;p&gt;At the scale of Wikipedia (~10 billion pageviews a month), even a single byte saving can mean terabytes worth of bandwidth saved.</text></item><item><author>arp242</author><text>A few years ago I did some measurements of popular projects (Wikipedia, WordPress, default React, jQuery, few things like that) comparing minify, minify+gzip, and just gzip, and found found that most minification beyond &amp;quot;removing comments&amp;quot; gives very little benefit even for poor 2G connections.&lt;p&gt;Especially things like removing as much whitespace as possible or replacing true&amp;#x2F;false with !0&amp;#x2F;!1 just don&amp;#x27;t really save a lot of space. The only two I found to make a significant difference were removing comments, and shortening identifiers (and usually with most of the savings being in &amp;quot;removing comments&amp;quot;, depending on the amount of comments and code style).</text></item></parent_chain><comment><author>distcs</author><text>&amp;gt; At the scale of Wikipedia (~10 billion pageviews a month), even a single byte saving can mean terabytes worth of bandwidth saved.&lt;p&gt;But does it really move the needle anywhere where it matters? If you are serving a million bytes in every response but you manage to trim a single byte from it, I don&amp;#x27;t think it is going to move the needle anywhere.&lt;p&gt;Sure it will save a terabyte when you have served a trillion responses. But in a trillion responses you are saving only one terabyte out of an exabyte of responses. That&amp;#x27;s not much!</text></comment>