Closed jrolfs closed 2 years ago
Thanks @jrolfs !
I'd be happy to open a pull request for this, but am curious if there's a preference as to how we resolve this (see above).
That would be nice, yeah. I think adding the package as a dev-dependency like we do in the other packages should be fine, what do you think?
Maybe also align the versions when you are on it anways. Looks like we have these two different versions atm:
I guess these could just be the same.
It would have to be a peer dependency (and therefore a peer dependency of cli and prompt) or direct dependency to resolve the issue. I think the peer dependency route would have to be a breaking change for both @commitlint/cli and @commitlint/prompt so maybe adding it as a direct dependency of @commitlint/load with a permissive range would be the best solution?
so maybe adding it as a direct dependency of @commitlint/load with a permissive range would be the best solution?
Got it, sounds good to me. Wanna give it a try?
Maybe also align the versions when you are on it anways. Looks like we have these two different versions atm:
"@types/node": "^12.20.27", "@types/node": "12.20.43",
I guess these could just be the same.
Also, I use manypkg in my monorepos to keep dependencies aligned. I could open another PR to add that here but there a quite a few fixes it would make:
Also, I use manypkg in my monorepos to keep dependencies aligned. I could open another PR to add that here but there a quite a few fixes it would make:
Didn't know the tool. Sounds good. Happy for a PR.
You think we should chose the higher working versions? I.e. chalk@^4.1.0
instead of the suggested chalk@^4.0.0
?
Released with v16.2.1
My yarn explain peer-requirements
currently complains about the following; which might be related to this original issue?
✘ @commitlint/load@npm:19.4.0 doesn't provide @types/node to cosmiconfig-typescript-loader@npm:5.0.0 [ac442]
✘ @commitlint/load@npm:19.4.0 doesn't provide typescript to cosmiconfig-typescript-loader@npm:5.0.0 [ac442] and 1 other dependency
Depending on @commitlint/prompt or @commitlint/cli results in peer dependency warnings because the @types/node peer dependency of cosmiconfig-typescript-loader is not satisfied in @commitlint/load
Depending on @commitlint/prompt or @commitlint/cli should not result in any peer dependency warnings.
Depending on @commitlint/prompt or @commitlint/cli results in peer dependency warnings.
Affected packages
Possible Solution
Either expose @types/node as a peer dependency of @commitlint/load and then of @commitlint/cli and @commitlint/prompt, or add @types/node as a dependency of @commitlint/load.
I'd be happy to open a pull request for this, but am curious if there's a preference as to how we resolve this (see above).
Steps to Reproduce (for bugs)
yarn init
yarn add @commitlint/cli
Context
Consolidate all JavaScript tooling into a single package https://github.com/hoverinc/hover-javascript/
Your Environment
commitlint --version
git --version
node --version