CSSO (CSS Optimizer) is a CSS minifier. It performs three sorts of transformations: cleaning (removing redundant), compression (replacement for the shorter forms), and restructuring (merge of declarations, rules, and so on). As a result, an output CSS becomes much smaller in size. One of CDN services like unpkg or jsDelivr can be used. By default (for short path) the ESM version is exposed. For IIFE version a full path to a bundle should be specified. CSSO is based on CSSTree to parse CSS into AST, AST traversal and to generate AST back to CSS. All CSSTree API is available behind syntax field extended with compress() method. You may minify CSS step by step. CSSO can use data about how CSS is used in the markup for better compression. File with this data (JSON) can be set using the usage option.

Features

  • Bundles are available for use in a browser
  • Minified IIFE with csso as global
  • One of CDN services like unpkg or jsDelivr can be used
  • Also syntax can be imported using csso/syntax entry point
  • Minify source CSS passed as String
  • Generate source map with respect of source map from input CSS

Project Samples

Project Activity

See All Activity >

License

MIT License

Follow CSSO

CSSO Web Site

Other Useful Business Software
Full-stack observability with actually useful AI | Grafana Cloud Icon
Full-stack observability with actually useful AI | Grafana Cloud

Our generous forever free tier includes the full platform, including the AI Assistant, for 3 users with 10k metrics, 50GB logs, and 50GB traces.

Built on open standards like Prometheus and OpenTelemetry, Grafana Cloud includes Kubernetes Monitoring, Application Observability, Incident Response, plus the AI-powered Grafana Assistant. Get started with our generous free tier today.
Create free account
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of CSSO!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript Software Development Software

Registered

2022-06-17