-
-
Notifications
You must be signed in to change notification settings - Fork 13
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
Remove unused Variables #112
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me!
CI passes, so generally the code still works. Missing imports would tend to error out early and loud, so I'm hoping CI is enough to catch these easily.
Thanks for the review @DeeDeeG! |
I was curious about these, but the few I found seem reasonable, and the convention about starting a var name with I'm honestly not as clear why those are ever super useful in JavaScript, and one or two of those aren't even unused, so it seems incorrect to start them with |
@DeeDeeG Merged this just as soon as you commented. But a followup PR to address any incorrect uses of But glad we are on the same page, it felt smart to leave these behind, since they are intentionally unused. As for the why, I feel like this convention comes up in most places where you are allowed to overload or underload the parameters of a function. Since leaving those unused values out could lead someone to misunderstand what parameters are expected, or could be available. I do see how it can make the API of some surfaces much easier to work with. |
This PR removes most of the unused variables within the codebase. Advised via the Codacy recommendations.
This also has a focus on imports mostly, and ignored any unused variables that begin with
_
for the time being.But for this PR while touching unrelated files, I hope keeping the purpose identical between all of them, it's not too hard to review.