-
Notifications
You must be signed in to change notification settings - Fork 332
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
Tie updates of Definitely Typed @types/
packages to their corresponding code package
#1415
Comments
Does |
(whoops, accidental close) Oh, I didn't know about As for peerDependencies for So we could query the Definitely Typed folks, and ask why they don't automatically add the appropriate peerDependencies to every They might say the peer dependency is implicit, with the version defined by the rules above, and adding |
@types/
packages to their corresponding code package@types/
packages to their corresponding code package
Okay, thanks for checking. I wasn't sure if they utilized peerDependencies or not.
I don't think that's realistic unfortunately. Plus, there may be good reasons why they don't specify
Going back to your original post...
What I would do in that situation is add the incompatible dependencies to the ncu reject list so that they are excluded from upgrades. Then you won't forget and accidentally upgrade them. You can lock down the
It looks like a good bit of work, but I like your idea of smarter upgrades for Definitely Typed packages. I don't have the bandwidth to add this feature, but let me know if you are interested and I can assist. |
Thank you for your detailed reply, and sorry for the delay in this one. Everything you said makes sense. I am juggling four unreleased open source projects of my own, so don't have the bandwidth at the moment. I guess we'll just leave this open? |
Per How do Definitely Typed package versions relate to versions of the corresponding library?:
When I run
ncu -i
in my project I get:I can't upgrade the latter two packages because of incompatibilities. So I have to (1) know about and remember the above quoted rule and (2) manually deselect the two
@types
upgrades.Ideally ncu is able to offer smarter guidance:
It shouldn't allow the user to install incompatible typings packages, or at least make it harder to do so.
It shouldn't always offer the absolute highest version of typings packages, but instead offer the highest version that is no higher than the corresponding installed library package.
Dynamic: when the user selects/deselects a library package for update,
it updates the choice for the corresponding typings package, updating
the target version, or graying it out entirely if the only available
newer typings package is incompatible with the library package installed
or that will be installed by ncu in the current session.
Grouped: typings packages don't exist on their own line, and are either
added to the same line as the library package, e.g. something like:
or as a subitem:
The text was updated successfully, but these errors were encountered: