-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Closed
Description
Describe the bug
Using named slots with a name that is a reserved keyword in JS, will create a broken snippet ππ»
Probably all of these will affect migration => https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Lexical_grammar#keywords
Create a PR that will re-use the @migration-task logic => #14278
Reproduction
having
<slot name="new">
...
</slot>will create following in migration:
{#snippet new()}and results into the following error:
ts: 'new' is a reserved word in JavaScript and cannot be used here
Logs
No logs during migrationSystem Info
System:
OS: macOS 15.1
CPU: (11) arm64 Apple M3 Pro
Memory: 85.53 MB / 18.00 GB
Shell: 5.9 - /bin/zsh
Binaries:
Node: 20.13.1 - ~/.nvm/versions/node/v20.13.1/bin/node
npm: 10.5.2 - ~/.nvm/versions/node/v20.13.1/bin/npm
pnpm: 9.7.0 - ~/.nvm/versions/node/v20.13.1/bin/pnpm
bun: 1.1.30 - ~/.bun/bin/bun
Browsers:
Chrome: 130.0.6723.117
Safari: 18.1
npmPackages:
svelte: ^5.0.0 => 5.1.15Severity
annoyance
Metadata
Metadata
Assignees
Labels
No labels