Open DetachHead opened 1 year ago
8.33.0
eslint-plugin-svelte
2.32.4
<script lang='ts'> const foo = [1,2,3] as const </script> {#each foo as value} {/each}
no error, because the array cannot be changed so it's safe to iterate over it without a key
[6:1]: Each block should have a key (svelte/require-each-key)
https://sveltejs.github.io/eslint-plugin-svelte/playground/#eJwly0EOwiAQheGrTMZFNzTEuiOtFxEXhI7aSEAZaGIId5e22+/9r6ANM6HCkW1cPgmc8c+pS9xdtQewwXOCRwgwwe0sBnG5g+GDtR/lcWqp9uVExr72thWrcZlqU7lpRYExO2JUBXkll0hG+uYlUr/t/Zt+qIZa/4f9MVs=
Before You File a Bug Report Please Confirm You Have Done The Following...
What version of ESLint are you using?
8.33.0
What version of
eslint-plugin-svelte
are you using?2.32.4
What did you do?
What did you expect to happen?
no error, because the array cannot be changed so it's safe to iterate over it without a key
What actually happened?
Link to GitHub Repo with Minimal Reproducible Example
https://sveltejs.github.io/eslint-plugin-svelte/playground/#eJwly0EOwiAQheGrTMZFNzTEuiOtFxEXhI7aSEAZaGIId5e22+/9r6ANM6HCkW1cPgmc8c+pS9xdtQewwXOCRwgwwe0sBnG5g+GDtR/lcWqp9uVExr72thWrcZlqU7lpRYExO2JUBXkll0hG+uYlUr/t/Zt+qIZa/4f9MVs=