-
Notifications
You must be signed in to change notification settings - Fork 20
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
Feature Request: Add ability to ignore some peerDependencies #206
Comments
I have opened a PR for this here: #207 |
This shouldn’t be supported. Two packages is a much much better way to manage this - it’s why the Airbnb config has two packages. |
Yeah, we were tryna avoid publishing multiple packages. coz we'll potentially have 3 packages; one for JS, one that extends Js to provide TS support and finally one that extends the TS one to provide react support. If we make changes and bump the base package then we'll need to bump the base-package versions on the other two packages. Plus the packages are really small since they are just extending airbnb config and then overriding a few rules, just felt like an overkill separating them out just because there are some peer deps we do not need. I know this' a real edge case 😅 and I guess we can figure out something in house. 😄 |
The proper granularity here is definitely “package”. Yes, i understand via maintaining the Airbnb config that this can be annoying, but it’s far better than the alternative. |
Context
We are writing a eslint config that can be used to lint react and non-react projects (also ts and non-ts apps). I know we could write and publish them as different packages each with its own package.json and publish them individually to npm. However, we have one package with all the config separated into different files, each with a specific purpose i.e., only lints JS or TS or react.
Challenge
The challenge comes when installing the peerdeps; if we only want to use the TS-specific config, we do not need to pull react-specific stuff. So we need a way to omit these deps while installing the package.
Possible approach
Allow removing deps with certain keywords, i.e., a user can run
npx install-peerdeps --omit-with-keywords="react, typescript" PACKAGE_NAME
. The keywords can be a list of comma-separated values.The text was updated successfully, but these errors were encountered: