Suggest using the bind operator over Function methods or Reflect.apply.
npm install eslint-plugin-prefer-bind-operatorSuggest using the bind operator over Function methods or Reflect.apply.
Warns for the following:
``js`
// with at least one argument
var foo = bar.bind(/ ... /);
foo.call(/ ... /);
foo.apply(/ ... /);
Reflect.apply(foo);
npm i --save-dev eslint-plugin-prefer-bind-operator
`json``
{
"plugins": [
"prefer-bind-operator"
],
"rules": {
"prefer-bind-operator/prefer-bind-operator": 2
}
}