fix: prefer-rest-params

```
/Users/1ambda/github/apache/apache-zeppelin/zeppelin-master/zeppelin-web/src/app/notebook/paragraph/paragraph.controller.js (2/0)
  ✖  1081:28  Use the rest parameters instead of 'arguments'  prefer-rest-params
  ✖  1082:66  Use the rest parameters instead of 'arguments'  prefer-rest-params

/Users/1ambda/github/apache/apache-zeppelin/zeppelin-master/zeppelin-web/src/app/notebook/paragraph/result/result.controller.js (2/0)
  ✖  967:28  Use the rest parameters instead of 'arguments'  prefer-rest-params
  ✖  968:66  Use the rest parameters instead of 'arguments'  prefer-rest-params
```
This commit is contained in:
1ambda 2017-04-15 01:50:34 +09:00
parent e3f9641cb2
commit a20d20e329
4 changed files with 6 additions and 1 deletions

View file

@ -31,7 +31,6 @@
"process": false
},
"rules": {
"prefer-rest-params": 0,
"prefer-spread": 0,
"no-redeclare": 0,
"no-var": 0,

View file

@ -156,10 +156,12 @@ export default class HandsonHelper {
if (colType === 'numeric' && this._isNumeric(value)) {
cellProperties.format = '0,0.[00000]';
td.style.textAlign = 'left';
// eslint-disable-next-line prefer-rest-params
Handsontable.renderers.NumericRenderer.apply(this, arguments);
} else if (value.length > '%html'.length && value.substring(0, '%html '.length) === '%html ') {
td.innerHTML = value.substring('%html'.length);
} else {
// eslint-disable-next-line prefer-rest-params
Handsontable.renderers.TextRenderer.apply(this, arguments);
}
}

View file

@ -1115,7 +1115,9 @@ function ParagraphCtrl ($scope, $rootScope, $route, $window, $routeParams, $loca
if (varName.indexOf(ANGULAR_FUNCTION_OBJECT_NAME_PREFIX) === 0) {
var funcName = varName.substring((ANGULAR_FUNCTION_OBJECT_NAME_PREFIX).length);
scope[funcName] = function () {
// eslint-disable-next-line prefer-rest-params
scope[varName] = arguments;
// eslint-disable-next-line prefer-rest-params
console.log('angular function (paragraph) invoked %o', arguments);
};

View file

@ -964,7 +964,9 @@ function ResultCtrl ($scope, $rootScope, $route, $window, $routeParams, $locatio
if (varName.indexOf(ANGULAR_FUNCTION_OBJECT_NAME_PREFIX) === 0) {
var funcName = varName.substring((ANGULAR_FUNCTION_OBJECT_NAME_PREFIX).length);
scope[funcName] = function () {
// eslint-disable-next-line prefer-rest-params
scope[varName] = arguments;
// eslint-disable-next-line prefer-rest-params
console.log('angular function (paragraph) invoked %o', arguments);
};