npm / sass-loader
sass-loader
What changed in sass-loader 16 to 17, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-17.
3 breaking1 performance1 behavior and defaults3 tooling2 fixes and other
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initsass-loader 177 changes
Breaking changes 3
Support for the legacy Sass JS API has been removed.
The minimum supported NodeJS version is now 22.11.0.
Support for node-sass has been removed.
Behavior and default changes 1
The api option now defaults to auto, which enables the modern compiler when supported and reuses a long-running compiler across files; otherwise it falls back to the modern API.
Tooling 2
The exports field exposes both ESM and CommonJS builds, allowing ESM consumers to import the loader directly while CommonJS consumers continue to use require.
Types have been added.
Fixes and other changes 1
Removes the BOM from compiled CSS and shifts source maps accordingly, preventing it from breaking a CSS rule when tools move @import at-rules above it.
sass-loader 163 changes
Performance 1
Caches filesystem calls for the modern API.
Tooling 1
Updates the peer dependency for @rspack/core v2, allowing sass-loader to declare compatibility with it.
Fixes and other changes 1
Normalizes separators in getPossibleRequests on Windows.