-
-
Notifications
You must be signed in to change notification settings - Fork 477
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
eslint: no-undef: also triggers for builtins and undefined assignment #3374
Comments
Just re-checked it with 0.6.0:
And still fails for |
I can't reproduce this by adding |
So this has something to do with our eslintrc.json. I'll try to investigate this further, as this seems to be an eslint config issue, shall I open a new issue? https://github.com/cockpit-project/cockpit-podman/blob/main/.eslintrc.json |
So my theory is that And indeed, changing the configuration to:
Makes |
This fixes commit dbbb6fc. Closes oxc-project#3374
All that's left now seems to be:
That's not in the GLOBALS in eslint so I am not sure how they detect that. |
It seems like the scopes for functions always contains the arguments. |
Yup, that should be the case, something to fix as follow up :) |
The rule defined here for eslint triggers for builtins such as
String
,parseInt
,JSON
,Array
all should be available.Relevant eslintrc.json config:
So I haven't seen warnings for
console
being undefined.And for assignment where the a variable is assigned to
undefined
.The text was updated successfully, but these errors were encountered: