-
Notifications
You must be signed in to change notification settings - Fork 13k
Closed
Labels
Domain: lib.d.tsThe issue relates to the different libraries shipped with TypeScriptThe issue relates to the different libraries shipped with TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issueSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
Some tag names of HTML and SVG are conflicted. So merging these two is wrong. ElementTagNameMap
has to split into HTMLElementTagNameMap
and SVGElementTagNameMap
.
For example, a
tag is defined in both HTML and SVG.
https://developer.mozilla.org/en-US/docs/Web/HTML/Element
https://developer.mozilla.org/en-US/docs/Web/SVG/Element
So the result type of document.querySelector('a')
is defined as HTMLAnchorElement
by TypeScript, but the actual type is HTMLAnchorElement | SVGAElement
.
related: #14783
shirakaba
Metadata
Metadata
Assignees
Labels
Domain: lib.d.tsThe issue relates to the different libraries shipped with TypeScriptThe issue relates to the different libraries shipped with TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issueSuggestionAn idea for TypeScriptAn idea for TypeScript