3.1.0 β’ Published 9 months ago
@putout/plugin-remove-unreferenced-variables v3.1.0
@putout/plugin-remove-unreferenced-variables
A variable is a named reference to a value.
(c) MDN
πPutout plugin adds ability to find and remove variables without references.
Install
npm i @putout/plugin-remove-unreferenced-variables -D
Rule
{
"rules": {
"remove-unreferenced-variables": "on"
}
}
β Example of incorrect code
let a;
let b;
a = 5;
b = 6;
console.log(a);
β Example of correct code
let a;
a = 5;
console.log(a);
License
MIT