DEV Community

Discussion on: How to keep Tailwind DRY

iamntz profile image
Ionut Staicu

Even then, GZIP can compress Tailwind classes much smaller than BEM classes due to how similar many of the classes are

Actually... not really. The simplistic way archiving works (be it gzip or anything else) is that it:

  1. splits the whole thing (what needs to be compressed) into blocks for 4-8-16kb
  2. creates a dictionary for repeating chars in each of this block

That's why text documents compress so well.

The size argument is not valid, the gain is marginally in most cases.

Some comments have been hidden by the post's author - find out more