-
Notifications
You must be signed in to change notification settings - Fork 97
Open
Labels
help wantedSuitable for a community contribution.Suitable for a community contribution.
Description
Google's AMP dictates that CSS stylesheets should be no larger than 50 kB (along with other requirements such as having everything inline and/or async loaded using JS, which doesn't apply here). I think that could be a good thing to try to achieve here as well -- while the compressed version is now at ~10.0 kB, the uncompressed one is ~70 kB.
Most responsible for this growth are the recent plugin additions (plots and graphs), which add a lot of extra SVG styling. What could be done:
- Improve the
postprocess.pyscript to reduce file size even more (no indentation at all? no newlines?) - Manually compress the CSS (use a single
marginproperty instead of separatemargin-top,margin-bottometc.) - Reduce the amount of repeated lists of long selectors with a single selector containing more properties (e.g., repeating
color: #ff3366five times is better than repeatingtable.m-table tr.m-danger td a:hoverfive times) - Port to the native CSS grids (CSS Grids #31), which could make the majority of
m-grid.cssobsolete (it's 13 kB now) - Use the
:is()selector (Rewrite many selectors with:is()to reduce size #208)
Any further ideas?
Metadata
Metadata
Assignees
Labels
help wantedSuitable for a community contribution.Suitable for a community contribution.
Projects
Status
TODO