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
4:44 warning 'config' is defined but never used no-unused-vars
Expected output: No warning.
The default behavior of eslint is to only warn on unused parameters that come after the last used parameter. jsx-uses-vars flags Wrapped as used but it leaves config marked as unused. Should this be picked up automatically by eslint? Or, will this require some heroics on the part of the react plugin to find these and fix them?
The text was updated successfully, but these errors were encountered:
Separately, I would expect config to be left marked as unused, because it is unused - the default settings for no-unused-vars, for the "args" setting is indeed after-used, but I would assume this is something eslint can figure out.
If it's not figuring it out, then I think that's a bug in no-unused-vars - specifically, it might have to wait to do its checking on program exit to ensure all the variables have time to be marked as used.
I'm filing this one here, though it could be something that will need followup elsewhere.
eslint@5.6.1
eslint-plugin-react@7.11.1
Given the following code:
And the following
.eslintconfig.json
:The following warning is given:
Expected output: No warning.
The default behavior of eslint is to only warn on unused parameters that come after the last used parameter.
jsx-uses-vars
flagsWrapped
as used but it leavesconfig
marked as unused. Should this be picked up automatically by eslint? Or, will this require some heroics on the part of the react plugin to find these and fix them?The text was updated successfully, but these errors were encountered: