sass

v1.99.0 MIT

A pure JavaScript implementation of Sass.

Weekly Downloads
21.5M
Stars
4.2K
Forks
378
Open Issues
67
Gzip Size
706.8 kB
Unpacked Size
5.9 MB
Dependencies
2
Last Updated
2mo ago

sass Download Trends

Download trends for sass028.7M57.3M86.0M114.6MFeb 2025MayAugNovFebApr 2026
sass

About sass

The `sass` package provides a pure JavaScript implementation of Sass, a popular CSS preprocessor.

It addresses the need for developers to write more maintainable, scalable, and organized CSS by introducing features like variables, nesting, mixins, and inheritance.

This implementation is based on Dart Sass, which is the primary reference implementation and generally the most performant and up-to-date version.

The primary audience for this package includes front-end developers and teams looking to enhance their CSS workflow beyond plain CSS.

Key API patterns leverage the programmatic API, allowing Sass to be integrated into build tools and custom build processes through functions and importers.

With 26.1 million weekly downloads and 4.2K GitHub stars, it indicates significant community adoption and trust, although its 5.9 MB unpacked size and 706.8 kB gzipped size represent a trade-off for its rich feature set compared to lighter alternatives.

When to use

  • When needing to leverage Sass features like variables, nesting, and mixins to organize and abstract CSS.
  • When integrating Sass compilation directly into a JavaScript-based build system or custom tooling.
  • When requiring programmatic control over the Sass compilation process via its API functions.
  • When working within ecosystems that heavily rely on Sass and require a dependency-free JavaScript solution.
  • When needing to import and process CSS and Sass files dynamically within the application runtime.
  • When migrating existing Sass projects that require a consistent, feature-complete Sass compiler.

When NOT to use

  • If only basic CSS features are required, consider plain CSS or a simpler CSS-in-JS solution.
  • If minimizing client-side JavaScript bundle size is a critical concern, explore server-side Sass compilation or lighter CSS preprocessors.
  • If the project relies heavily on browser-specific CSS features that are not well-supported by Sass preprocessor rules.
  • If absolute minimal build tool dependencies are a priority, a command-line Sass executable might be more appropriate.
  • When targeting environments with very limited JavaScript runtime capabilities or memory constraints.

sass Alternatives

sass Categories