Svelte 5: svelte-ignore unused-export-let
is ignored
#11890
Labels
Milestone
svelte-ignore unused-export-let
is ignored
#11890
Describe the bug
When I build my Sveltia CMS app with Svelte 5 RC, I see a bunch of warnings about unused exports, e.g.
Here’s the relevant code.
I’ve noticed in #11833 that at some point
svelte-ignore unused-export-let
has becomesvelte-ignore export_let_unused
. I can confirm that changingunused-export-let
toexport_let_unused
can silence the warnings.If it’s an intentional change, please mention it in the breaking changes document. Otherwise, please restore the support for
unused-export-let
and possibly other warning codes.Additional context: These unused exports are used along with
svelte-ignore unused-export-let
to suppress browser console warnings like<String_editor> was created with unknown prop 'locale'
. These components are loaded with<svelte:component>
, and not all the components use all the props. It may no longer be necessary after migrating to the Svelte 5$props
rune (I haven’t tested it yet.) (Edit: it seems so, according to #4652)Reproduction
pnpm install svelte@next -D && pnpm build
Logs
No response
System Info
System: OS: macOS 14.5 CPU: (12) x64 Intel(R) Core(TM) i7-9750H CPU @ 2.60GHz Memory: 549.19 MB / 16.00 GB Shell: 3.2.57 - /bin/bash Binaries: Node: 20.14.0 - /usr/local/opt/node@20/bin/node Yarn: 1.22.22 - /usr/local/bin/yarn npm: 10.7.0 - /usr/local/opt/node@20/bin/npm pnpm: 9.1.4 - /usr/local/bin/pnpm Browsers: Chrome: 125.0.6422.142 Firefox Nightly: 124.0a1 Safari: 17.5 npmPackages: svelte: 5.0.0-next.148 => 5.0.0-next.148
Severity
annoyance
The text was updated successfully, but these errors were encountered: