Skip to content

Commit

Permalink
perf: ⚡️ remove support for deprecated node-sass
Browse files Browse the repository at this point in the history
node-sass was deprecated a while ago:
https://sass-lang.com/blog/libsass-is-deprecated

BREAKING CHANGE: 🧨 node-sass is not supported anymore. Use `sass` instead
  • Loading branch information
kaisermann committed Dec 10, 2022
1 parent ba4299d commit a617fe1
Show file tree
Hide file tree
Showing 8 changed files with 17 additions and 770 deletions.
2 changes: 1 addition & 1 deletion docs/getting-started.md
Expand Up @@ -31,7 +31,7 @@ $ npm install -D svelte-preprocess
- PostCSS: `npm install -D postcss postcss-load-config`
- SugarSS: `npm install -D postcss sugarss`
- Less: `npm install -D less`
- Sass: `npm install -D node-sass` or `npm install -D sass`
- Sass: `npm install -D sass`
- Pug: `npm install -D pug`
- Stylus: `npm install -D stylus`

Expand Down
1 change: 0 additions & 1 deletion docs/preprocessing.md
Expand Up @@ -354,7 +354,6 @@ The `scss/sass` preprocessor accepts the default sass options alongside two othe
| Option | Default | Description |
| ---------------- | ----------- | ------------------------------------------------------------------------------------------------------------------------------ |
| `renderSync` | `false` | if `true`, use the sync render method which is faster for dart sass. |
| `implementation` | `undefined` | pass the module to use to compile sass, if unspecified, `svelte-preprocess` will first look for `node-sass` and then for Sass. |

You can check the [Sass API reference](https://sass-lang.com/documentation/js-api/modules#LegacyOptions) for specific Sass options. The `file` and `data` properties are not supported. Instead, use the `prependData` property if you want to prepend some content to your `scss` content.

Expand Down
9 changes: 2 additions & 7 deletions package.json
Expand Up @@ -33,7 +33,7 @@
"test": "jest",
"lint": "eslint --ext js,ts .",
"format": "prettier --write \"**/*.{ts,js,json}\"",
"postinstall": "echo \"[svelte-preprocess] Don't forget to install the preprocessors packages that will be used: node-sass/sass, stylus, less, postcss & postcss-load-config, coffeescript, pug, etc...\"",
"postinstall": "echo \"[svelte-preprocess] Don't forget to install the preprocessors packages that will be used: sass, stylus, less, postcss & postcss-load-config, coffeescript, pug, etc...\"",
"version": "conventional-changelog -p angular -i CHANGELOG.md -s -r 1 && git add CHANGELOG.md",
"patch": "npm version patch -m 'chore(release): %s'",
"minor": "npm version minor -m 'chore(release): %s'",
Expand All @@ -60,7 +60,7 @@
"pre-commit": "lint-staged",
"pre-push": "tsc --noEmit",
"commit-msg": "commitlint -E HUSKY_GIT_PARAMS",
"post-merge": "yarn"
"post-merge": "pnpm install"
}
},
"lint-staged": {
Expand All @@ -82,7 +82,6 @@
"@types/babel__core": "^7.1.19",
"@types/jest": "^27.0.2",
"@types/node": "^14.0.11",
"@types/node-sass": "^4.11.3",
"@types/stylus": "^0.48.32",
"autoprefixer": "^9.8.0",
"babel-minify": "^0.5.1",
Expand All @@ -93,7 +92,6 @@
"jest": "^27.2.4",
"less": "^3.11.3",
"lint-staged": "^10.5.3",
"node-sass": "^8.0.0",
"postcss": "^8",
"postcss-easy-import": "^3.0.0",
"postcss-load-config": "^3.0.0",
Expand Down Expand Up @@ -137,9 +135,6 @@
"less": {
"optional": true
},
"node-sass": {
"optional": true
},
"postcss": {
"optional": true
},
Expand Down

0 comments on commit a617fe1

Please sign in to comment.