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
refactor(MessageEmbed): Deprecate strings for setAuthor()
(completely) and setFooter()
#7153
Conversation
Why can't builders be changed to support the current implementation? I think it makes much more sense to do that instead |
I'm not a fan of this required parameters provided 1 after the other with an optional object for optional parameters at all, and I don't know if the others are or aren't on the same page. What is each of those parameters?? You don't know by name, unless you read the docs or hover over the function definition in your editor, whereas with objects you know from the getgo what's what |
VSCode actually introduced a feature recently with TS 4.5 that adds the name of the parameter to the function call so unless you have a variable called text and set that in the text parameter of the footer, it will display as |
Yeah, try doing that on a PR review in GitHub or anywhere else that isn't powered by TypeScript. While you have inlay hints in VSCode (btw, I don't, I didn't enable them yet), you have to consider for the cases where such hints just don't exist, and some people (including me) have to deal with that a lot. Objects are far better in this case because they're named and doesn't depend on inlays or any IDE hints to be properly read and/or understood. |
Well if you’re reviewing a PR you should probably know how the library works to begin with so that shouldn’t be an issue |
That's missing the point that not everyone is using TypeScript, not everyone is using VSCode/IntelliJ, and that in the end an object doesn't cause any harm at all. |
Please describe the changes this PR makes and why it should be merged:
Due to #7067,
setAuthor()
andsetFooter()
should only passing objects and not strings as per the builder's implementation. This pull request deprecates the passing of strings.Status and versioning classification: