Node-sass is a library that provides binding for Node.js to LibSass, the C version of the popular stylesheet preprocessor, Sass. It allows you to natively compile .scss files to css at incredible speed and automatically via a connect middleware. A custom importer allows extension of the LibSass engine in both a synchronous and asynchronous manner. In both cases, the goal is to either return or call done() with an object literal. When returning or calling done() with { file: "String" }, the new file path will be assumed for the @import. It's recommended to be mindful of the value of prev in instances where relative path resolution may be required. When returning or calling done() with { contents: "String" }, the string value will be used as if the file was read in through an external source.

Features

  • node-sass supports standard node style asynchronous callbacks
  • The interface for command-line usage is fairly simplistic
  • In error conditions, the error argument is populated with the error
  • In success conditions, the result object is populated with an object describing the result of the render call
  • node-sass/libsass will compile a mixed library of scss and indented syntax (.sass) files with the Default setting (false) as long as .sass and .scss extensions are used in filenames
  • Importers can return error and LibSass will emit that error in response

Project Samples

Project Activity

See All Activity >

Categories

Compilers

License

MIT License

Follow node-sass

node-sass Web Site

Other Useful Business Software
Earn up to 15% annual interest with Nexo. Icon
Earn up to 15% annual interest with Nexo.

Access competitive interest rates on your digital assets.

Generate interest, borrow against your crypto, and trade a range of cryptocurrencies — all in one platform. Geographic restrictions, eligibility, and terms apply.
Get started with Nexo.
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of node-sass!

Additional Project Details

Operating Systems

Mac, Windows

Programming Language

C++

Related Categories

C++ Compilers

Registered

2021-07-19