My initial assumption is that snippets in Svelte 5 act like hoisted functions. However, it appears that ESLint does not recognize them as such. As a result, when these snippets are utilized within a Githubissues.
Githubissues is a development platform for aggregating issues.
Before You File a Bug Report Please Confirm You Have Done The Following...
What version of ESLint are you using?
8.56.0
What version of
eslint-plugin-svelte
are you using?2.36.0-next.4
What did you do?
Configuration
``` /** @type { import("eslint").Linter.Config } */ module.exports = { root: true, extends: [ 'eslint:recommended', 'plugin:@typescript-eslint/recommended', 'plugin:svelte/recommended', 'prettier' ], parser: '@typescript-eslint/parser', plugins: ['@typescript-eslint'], parserOptions: { sourceType: 'module', ecmaVersion: 2020, extraFileExtensions: ['.svelte'] }, env: { browser: true, es2017: true, node: true }, overrides: [ { files: ['*.svelte'], parser: 'svelte-eslint-parser', parserOptions: { parser: '@typescript-eslint/parser' } } ] }; ```What did you expect to happen?
No errors.
What actually happened?
ESLint reported two contractory errors:
Link to GitHub Repo with Minimal Reproducible Example
https://github.com/nicksulkers/eslint-svelte5-snippets-bug-repro
Additional comments
My initial assumption is that snippets in Svelte 5 act like hoisted functions. However, it appears that ESLint does not recognize them as such. As a result, when these snippets are utilized within a Githubissues.