Closed dslatkin closed 2 years ago
So with Jason's help on the Svelte Discord, I figured out the issue was the bundled version of Node that ships with VS Code doesn't yet support String.prototype.replaceAll
. Changing the extension setting svelte.language-server.runtime
to explicitly point to my Node executable at /usr/local/bin/node
fixed the issue.
Thank you!
Yeah I was just thinking it has to be a node issue, but since you have node 16 I was confused. We can rebuild that function to use global regexes ..
Just to add on to this:
Node 14 throws this error. Node 16 doesn't throw this error. If you're using .nvm
, set your .nvmrc
to 16 or run nvm use 16
before running rpm run dev
to avoid this error.
Describe the bug
I see the following error exposed by the Svelte VS Code extension on any component that has at least one element with a class:
Looking at the Svelte extension output, this is the stack trace for the error:
I'm happy to help if you need any more information. Thanks!
System Info
Used Package Manager
npm