simonwep / simonwep/vite-plugin-optimize-css-modules

A different dictionary can trivially improve g-zip compress ratio

Open
#8 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

improvement
Dominant language
CSS
Stars
48
Forks
5
PR merge metrics
No merged PRs in 30d

Description

Currently, the default dictionary is: _-abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789

Based on a character frequency analysis of the code in a few of my projects it should be re-ordered to this: etionraldfps0gx-1chbum4v6w25k9y873zjHCONADLYqBEFGIJKMPQRSTUVWXZ_

For me this measurably improved g-zip compression ratio without any cost. Perhaps a deeper analysis could be done for the most optimal default dictionary, but this is at least a step in the right direction.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Start by locating the implementation of the default dictionary in the repository, then compare the current and proposed character orders with representative gzip output. Done means the default dictionary is updated or the optimization is rejected with measured results and coverage for the affected behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
css, vite
Domain
build-system, performance
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.