Open laztheripper opened 1 year ago
Can you give some information on what plugins are you having for svelte on VS Code? This seems to be some kind of warning by the plugins more than Svelte itself
From your reproduction, you indeed didn't use the id props. So the warning should be correct. Are you missing something from the reproduction? Or what were you expected it to be?
You probably want to put this in your vscode workspace settings:
"svelte.plugin.svelte.compilerWarnings": { "unused-export-let": "ignore", }
Describe the bug
I have a filtered array of components to display, so I use
<svelte:component {id} this={tab} />
in the parent.In the child components I have
export let id = "";
However, vscode is telling me:I am unsure where the warning is coming from, but the code does compile and the value can be read correctly on the front-end. The only solution I've found to suppress the warning in my vscode editor is to add
<!-- svelte-ignore unused-export-let -->
to the top of every affected child component.Thank you.
Reproduction
Parent
Child
Logs
No response
System Info
Severity
annoyance