Skip to content

Make node-sass optional in peerDependencies #55

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions package.json
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The patch version of the package should also be increased by 1:
line 3 : 3.0.0 -> 3.0.1

As 3.0.0 already exists as a NPM package:
https://www.npmjs.com/package/sass-extract?activeTab=versions

Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@
"node-sass": ">=3.8.0",
"sass": ">=1"
},
"peerDependenciesMeta": {
Copy link

@cduivis cduivis Jan 8, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey I'm not the maintainer of this package, but I was also looking at creating a PR when I found yours.

TLDR: My suggestion is to also update the engine node version to at least 10.

Reasoning:

peerDependenciesMeta is a feature introduced in NPM 7, which was released with Node version 15.
If I take a look at the release notes from that time. NPM 7 only works with Node versions 10 and up:
image
https://docs.npmjs.com/cli/v7/using-npm/changelog#some-high-level-changes-and-improvements

So on line 29 I would also upgrade node "node": ">=4" towards at least "node": ">=10".

"node-sass": {
"optional": true
}
},
"dependencies": {
"bluebird": "^3.7.2",
"fs-monkey": "^1.0.4",
Expand All @@ -40,6 +45,7 @@
"query-ast": "^1.0.2"
},
"devDependencies": {
"node-sass": ">=3.8.0",
"babel-cli": "^6.26.0",
"babel-core": "^6.26.3",
"babel-preset-es2015": "^6.24.1",
Expand Down