This repository was archived by the owner on Sep 18, 2023. It is now read-only.
This repository was archived by the owner on Sep 18, 2023. It is now read-only.
file-name-matches-element
: TypeError: Cannot read properties of null (reading 'name') #57
Closed
Description
Linted Line:
window.customElements.define('foo-bar', class extends HTMLElement {
Error:
TypeError: Cannot read properties of null (reading 'name')
Rule: "custom-elements/file-name-matches-element"
at :matches(ClassDeclaration, ClassExpression)[superClass.name=/HTML.*Element/] (node_modules/eslint-plugin-custom-elements/lib/rules/file-name-matches-element.js:51:30)
at ruleErrorHandler (node_modules/eslint/lib/linter/linter.js:1093:28)
at node_modules/eslint/lib/linter/safe-emitter.js:45:58
at Array.forEach (<anonymous>)
at Object.emit (node_modules/eslint/lib/linter/safe-emitter.js:45:38)
at NodeEventGenerator.applySelector (node_modules/eslint/lib/linter/node-event-generator.js:297:26)
at NodeEventGenerator.applySelectors (node_modules/eslint/lib/linter/node-event-generator.js:326:22)
at NodeEventGenerator.enterNode (node_modules/eslint/lib/linter/node-event-generator.js:340:14)
at CodePathAnalyzer.enterNode (node_modules/eslint/lib/linter/code-path-analysis/code-path-analyzer.js:795:23)
at node_modules/eslint/lib/linter/linter.js:1128:32
Metadata
Metadata
Assignees
Labels
No labels