From 756fcd391122e1580f9293cb62897ba0bee73222 Mon Sep 17 00:00:00 2001 From: Natalie Weizenbaum Date: Tue, 26 Oct 2021 14:06:40 -0700 Subject: [PATCH] Fix the logger option for render() (#1538) Closes #1533 --- CHANGELOG.md | 6 ++++++ lib/src/node/legacy.dart | 4 +++- pkg/sass_api/CHANGELOG.md | 4 ++++ pkg/sass_api/pubspec.yaml | 4 ++-- pubspec.yaml | 2 +- 5 files changed, 16 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 5de856de..609d8663 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## 1.43.4 + +### JS API + +* Fix a bug where the `logger` option was ignored for the `render()` function. + ## 1.43.3 * Improve performance. diff --git a/lib/src/node/legacy.dart b/lib/src/node/legacy.dart index 9714eb64..7a6e705e 100644 --- a/lib/src/node/legacy.dart +++ b/lib/src/node/legacy.dart @@ -84,7 +84,9 @@ Future _renderAsync(RenderOptions options) async { quietDeps: options.quietDeps ?? false, verbose: options.verbose ?? false, charset: options.charset ?? true, - sourceMap: _enableSourceMaps(options)); + sourceMap: _enableSourceMaps(options), + logger: NodeToDartLogger( + options.logger, Logger.stderr(color: hasTerminal))); } else if (file != null) { result = await compileAsync(file, nodeImporter: _parseImporter(options, start), diff --git a/pkg/sass_api/CHANGELOG.md b/pkg/sass_api/CHANGELOG.md index 0536bda8..5cbce6a0 100644 --- a/pkg/sass_api/CHANGELOG.md +++ b/pkg/sass_api/CHANGELOG.md @@ -1,3 +1,7 @@ +## 1.0.0-beta.18 + +* No user-visible changes. + ## 1.0.0-beta.17 * No user-visible changes. diff --git a/pkg/sass_api/pubspec.yaml b/pkg/sass_api/pubspec.yaml index bec75b19..9e1c8c80 100644 --- a/pkg/sass_api/pubspec.yaml +++ b/pkg/sass_api/pubspec.yaml @@ -2,7 +2,7 @@ name: sass_api # Note: Every time we add a new Sass AST node, we need to bump the *major* # version because it's a breaking change for anyone who's implementing the # visitor interface(s). -version: 1.0.0-beta.17 +version: 1.0.0-beta.18 description: Additional APIs for Dart Sass. homepage: https://github.com/sass/dart-sass @@ -10,7 +10,7 @@ environment: sdk: '>=2.12.0 <3.0.0' dependencies: - sass: 1.43.3 + sass: 1.43.4 dependency_overrides: sass: {path: ../..} diff --git a/pubspec.yaml b/pubspec.yaml index 5884225d..a6663d9e 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,5 +1,5 @@ name: sass -version: 1.43.3 +version: 1.43.4 description: A Sass implementation in Dart. homepage: https://github.com/sass/dart-sass