9984 })(FilterItem)
9985 const FilterItemSelect = (function (_super) {
9986 function FilterItemSelect () {
9987 return (_super !== null && _super.apply(this, arguments)) || this 9988 }
9989 return (
9990 __extends(FilterItemSelect, _super),
9952 })()
9953 const FilterItemCheckbox = (function (_super) {
9954 function FilterItemCheckbox () {
9955 return (_super !== null && _super.apply(this, arguments)) || this 9956 }
9957 return (
9958 __extends(FilterItemCheckbox, _super),
9272 )
9273 }),
9274 (e.Builder.prototype.use = function (e) {
9275 const t = Array.prototype.slice.call(arguments, 1) 9276 t.unshift(this), e.apply(this, t)
9277 }),
9278 (e.MatchData = function (e, t, r) {
8332 )
8333 }),
8334 (e.Pipeline.prototype.add = function () {
8335 Array.prototype.slice.call(arguments).forEach(function (t) { 8336 e.Pipeline.warnIfFunctionNotRegistered(t), this._stack.push(t)
8337 }, this)
8338 }),
8107 t && i.has(t, 'constructor')
8108 ? t.constructor
8109 : function () {
8110 return n.apply(this, arguments) 8111 }),
8112 i.extend(r, n, e),
8113 (r.prototype = i.create(n.prototype, t)),
There are rest parameters in ES2015
. We can use that feature for variadic functions instead of the arguments
variable.
arguments
does not have methods of Array.prototype
, so it's a bit of an inconvenience.
function foo() {
console.log(arguments);
}
function foo(action) {
var args = Array.prototype.slice.call(arguments, 1);
action.apply(null, args);
}
function foo(action) {
var args = [].slice.call(arguments, 1);
action.apply(null, args);
}
function foo(...args) {
console.log(args);
}
function foo(action, ...args) {
action.apply(null, args); // or `action(...args)`, related to the `prefer-spread` rule.
}
// Note: the implicit arguments can be overwritten.
function foo(arguments) {
console.log(arguments); // This is the first argument.
}
function foo() {
var arguments = 0;
console.log(arguments); // This is a local variable.
}