You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If two commands are registered with the same name, the last one registered replaces the original. But since we can't predict if users register default or custom commands last, it could lead to unintended overwriting of custom commands by default ones.
I think it's an accurate assumption that most people are registering built-in stuff first, but you know what they say about assumptions! Imo it risks introducing breaking changes, violating both semver and Cmdr's reputation for stability.
If there's a conflict between a built-in command or type and a developer-registered one, the developer one should take priority irrespective of which was registered later. For a conflict between two developer-registered commands, the one registered later should take priority (I believe this is the current behaviour.)
A warning should be emitted in either case so that way there's no surprises for the developer.
The text was updated successfully, but these errors were encountered:
Originally posted by @wilyt1 in #327 (comment)
I think it's an accurate assumption that most people are registering built-in stuff first, but you know what they say about assumptions! Imo it risks introducing breaking changes, violating both semver and Cmdr's reputation for stability.
If there's a conflict between a built-in command or type and a developer-registered one, the developer one should take priority irrespective of which was registered later. For a conflict between two developer-registered commands, the one registered later should take priority (I believe this is the current behaviour.)
A warning should be emitted in either case so that way there's no surprises for the developer.
The text was updated successfully, but these errors were encountered: