github-pages-deploy-action/node_modules/eslint-plugin-github/lib/rules/array-foreach.js
2020-03-06 22:45:40 -05:00

17 lines
310 B
JavaScript

module.exports = {
meta: {
docs: {},
schema: []
},
create(context) {
return {
CallExpression(node) {
if (node.callee.property && node.callee.property.name === 'forEach') {
context.report(node, 'Prefer for...of instead of Array.forEach')
}
}
}
}
}