Closed bkataru closed 9 months ago
Are you running eslint-plugin-svelte@next
? @bkataru
No im running version 2.35.1
Update to @next
and it will detect the runes. @latest
is still for latest Svelte 4 😃
running npm install eslint-plugin-svelte@next
doesnt work.
package.json
:
Describe the bug
I'm trying out Svelte 5 with SvelteKit 2 and TypeScript for a toy project with
eslint
andprettier
configured for linting and formatting respectively. It seems thateslint
does not recognize the new runes such as$props
and$state
even though type declarations exist for them.For the moment, I am able to get around this issue by configuring globals in
.eslintrc.cjs
but this seems more of a hack than an actual fix.I realize that this might be more of an issue with ESLint than Svelte 5 itself, so if someone can confirm that for me, I will open a bug report in the ESLint repo instead. Any help would be appreciated.
Reproduction
Here are the relevant config files and an example
+page.svelte
file that can reproduce the issue in a barebones starter SvelteKit 2 project.eslintrc.cjs
.prettierrc.json
package.json
svelte.config.js
tsconfig.json
vite.config.ts
+page.svelte
Logs
No response
System Info
Severity
blocking an upgrade