-
-
Notifications
You must be signed in to change notification settings - Fork 223
Closed
Labels
FixedFixed in master branch. Pending production release.Fixed in master branch. Pending production release.bugSomething isn't workingSomething isn't working
Description
Describe the bug
Creating a this binding on svg elements is not correctly typed.
To Reproduce
-
Create a fresh typescript template project.
-
Replace the content of
App.sveltewith:
<script lang="ts">
let group : SVGElement;
</script>
<main>
<svg>
<g bind:this={group}></g>
</svg>
</main>
- Run
npm run validate. The following error is returned.
./svelte-typescript-app/src/App.svelte:7:17
Error: Argument of type 'SVGElement' is not assignable to parameter of type 'HTMLElement'.
Type 'SVGElement' is missing the following properties from type 'HTMLElement': accessKey, accessKeyLabel, autocapitalize, dir, and 16 more. (ts)
Expected behavior
group should be of type SVGElement
System (please complete the following information):
- OS: macOS
- IDE: VSCode
- Plugin/Package: "Svelte for VSCode",
svelte-check
Metadata
Metadata
Assignees
Labels
FixedFixed in master branch. Pending production release.Fixed in master branch. Pending production release.bugSomething isn't workingSomething isn't working