Use 🐊Putout as babel plugin
.
-const s = 'hi';
$ npm install babel-plugin-putout
.babelrc.json
{
"plugins": [
["putout", {
"rules": {
"remove-unused-variables": false
}
}]
]
}
$ babel --plugins putout script.js
require('babel-core').transform('code', {
plugins: ['putout'],
});