Warn deprecated css.Sass

Hi,

I have installed hugo on Windows 11 now, but get the message:

WARN deprecated: css.Sass: libsass was deprecated in Hugo v0.153.0 and will be removed in a future release. Use dartsass instead. See css.Sass

Here is my hugo env:

hugo v0.159.0+extended+withdeploy windows/amd64 BuildDate=2026-03-23T18:16:59Z VendorInfo=gohugoio
GOOS=“windows”
GOARCH=“amd64”
GOVERSION=“go1.26.1”
github.com/webmproject/libwebp=“v1.6.0”
github.com/sass/libsass=“3.6.6”
github.com/sass/dart-sass/protocol=“3.2.0”
github.com/sass/dart-sass/compiler=“1.98.0”
github.com/sass/dart-sass/implementation="1.98.0"

I have followed this post on stackoverflow to set the path to dart-sass and added an alias for sass.bat .

Somewhere I saw this line: “If you have installed both, Hugo will use Dart Sass.

May be someone can hint me in the right direction. :slightly_smiling_face:

In the code where you call the css.Sass function, have you specified the transpiler option?

OK, you are right..

I had this line in my code:

{{ $opts := dict "transpiler" "libsass" "targetPath" "css/style.css" }}

Changed it to this now:

{{ $opts := dict "transpiler" "dartsass" "targetPath" "css/style.css" }}

Thanks @jmooring

1 Like

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.