(node)
| 180 | } |
| 181 | }, |
| 182 | MemberExpression(node) { |
| 183 | const obj = node.object.name; |
| 184 | const prop = node.property.name; |
| 185 | if (!prop || !isTarget(nameMap, obj) || isIgnored(nameMap, obj, prop)) { |
| 186 | return; |
| 187 | } |
| 188 | |
| 189 | const variables = |
| 190 | context.sourceCode.scopeManager.getDeclaredVariables(node); |
| 191 | if (variables.length === 0) { |
| 192 | context.report({ |
| 193 | node, |
| 194 | messageId: 'error', |
| 195 | data: { |
| 196 | name: toPrimordialsName(obj, prop), |
| 197 | }, |
| 198 | }); |
| 199 | } |
| 200 | }, |
| 201 | VariableDeclarator(node) { |
| 202 | const name = node.init?.name; |
| 203 | if (name === 'primordials' && node.id.type === 'ObjectPattern') { |
nothing calls this directly
no test coverage detected
searching dependent graphs…