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
Why is this reported as no-unused-vars? #12357
Comments
Hi @daningalla, thanks for the issue. It looks like there's not enough information for us to know how to help you. If you're reporting a bug, please be sure to include:
Requesting a new rule? Please see Proposing a New Rule for instructions. Requesting a rule change? Please see Proposing a Rule Change for instructions. If it's something else, please just provide as much additional information as possible. Thanks! |
Do you use If not, the lint message is correct- there's not much value in doing all of those replacements and reassigning to a variable you don't later use. |
@platinumazure The message indicates the unused var is |
This is why we ask for all the information about your use case... You didn't even include the error message, so I had to guess. 😄 Please provide all the info requested in this comment. Thanks! |
@platinumazure - gotcha, sorry. I edited the oc. |
Hi @daningalla. ESLint 1.13.0 doesn't exist. This is the version list: https://www.npmjs.com/package/eslint?activeTab=versions Please fill our issue template. People have many varied environments, so we need the information that is to reproduce your case in order to investigate it. Otherwise, what we can do is very limited. Just for information, we cannot reproduce your case on our online demo. I remember an old issue #12117 from your code. Would you check if it's your case? Thank you. |
Environment (from package-lock): Configuration
What parser (default, Babel-ESLint, etc.) are you using? babel-eslint What did you do? Please include the actual source code causing the issue, as well as the command that you used to run ESLint. Code in question:
Invoked using
What did you expect to happen? What actually happened? Please include the actual, raw output from ESLint.
This is precisely what was going on in #12117. Also sorry if I missed other info, as you can easily tell I'm just starting in the JS space... |
Have you tried the solution in that other issue? Looks like you might need to update babel-eslint. |
Thank you for filling the template. Okay, you look using problematic |
Thank you - will close. |
Line 90: 'entry' is defined but never used no-unused-vars
Edit:
version 1.13.0
what happened: The following warning was issued: 'Line 90: 'entry' is defined but never used no-unused-vars'
expected: since
entry
is used in the for loop body, I'd expect to not see that warningThe text was updated successfully, but these errors were encountered: