ut-tools
Version:
Build and Release management automation package.
14 lines (13 loc) • 430 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
var tooManyArguments = exports.tooManyArguments = function tooManyArguments(context) {
return {
CallExpression: function CallExpression(node) {
if (node.callee.name === 'require' && node.arguments.length > 1) {
context.report(node, 'require() called with extra arguments. Only one argument is expected', {});
}
}
};
};