(context)
| 15 | }, |
| 16 | }, |
| 17 | create(context) { |
| 18 | return { |
| 19 | CallExpression(node) { |
| 20 | // Check if the callee is Object.keys |
| 21 | if ( |
| 22 | node.callee.type === "MemberExpression" && |
| 23 | node.callee.object.type === "Identifier" && |
| 24 | node.callee.object.name === "Object" && |
| 25 | node.callee.property.type === "Identifier" && |
| 26 | node.callee.property.name === "keys" |
| 27 | ) { |
| 28 | context.report({ |
| 29 | node, |
| 30 | messageId: "useObjectKeys", |
| 31 | }); |
| 32 | } |
| 33 | }, |
| 34 | }; |
| 35 | }, |
| 36 | }; |
no outgoing calls