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
Sometimes when you are forced to initialize a variable (e.g. object destructuring to get the "rest" of the props) you want to ignore that variable. Using _ as the variable name is a convention taken from other languages (where it is sometimes more than just a convention). However, _ variables can trigger the no-shadow rule if you have nested uses.
We should upgrade our no-shadow to use the allow prop as explained at https://eslint.org/docs/rules/no-shadow#allow. We should allow any variables that are ignored under no-unused-vars.
The text was updated successfully, but these errors were encountered:
Sometimes when you are forced to initialize a variable (e.g. object destructuring to get the "rest" of the props) you want to ignore that variable. Using
_
as the variable name is a convention taken from other languages (where it is sometimes more than just a convention). However,_
variables can trigger theno-shadow
rule if you have nested uses.We should upgrade our
no-shadow
to use theallow
prop as explained at https://eslint.org/docs/rules/no-shadow#allow. We should allow any variables that are ignored underno-unused-vars
.The text was updated successfully, but these errors were encountered: