Correctly compile lang="sass" styles (#857)

* Added sass support

* Combined cases, added check for indentedSyntax

* Corrected changeset
This commit is contained in:
Tc001 2021-07-27 15:51:03 +03:00 committed by GitHub
parent 4591c1f5ad
commit b8af49f035
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 1 deletions

View file

@ -0,0 +1,5 @@
---
'astro': patch
---
Added sass support

View file

@ -109,7 +109,7 @@ async function transformStyle(code: string, { logging, type, filename, scopedCla
}
case 'sass':
case 'scss': {
css = sass.renderSync({ data: code, includePaths }).css.toString('utf8');
css = sass.renderSync({ data: code, includePaths, indentedSyntax: styleType === 'sass' }).css.toString('utf8');
break;
}
default: {