sveltejs / eslint-plugin-svelte

ESLint plugin for Svelte using AST
https://sveltejs.github.io/eslint-plugin-svelte/
MIT License
298 stars 36 forks source link

`<dialog bind:open>` shows error #612

Closed hyunbinseo closed 10 months ago

hyunbinseo commented 10 months ago

Before You File a Bug Report Please Confirm You Have Done The Following...

What version of ESLint are you using?

8.53.0

What version of eslint-plugin-svelte are you using?

2.35.0

What did you do?

Configuration ```ts // SvelteKit default 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', }, }, ], }; ```
<dialog bind:open={open}></dialog>

What did you expect to happen?

Both <details> and <dialog> have an open attribute. Therefore, it should be supported in the latter.

What actually happened?

'open' binding can only be used with <details>(invalid-binding)

eslint(svelte/valid-compile)

Link to GitHub Repo with Minimal Reproducible Example

Simply create a <dialog> element in a SvelteKit default template.

image

Additional comments

No response

hyunbinseo commented 10 months ago

bind:open is not supported in Svelte.