sveltejs / prettier-plugin-svelte

Format your svelte components using prettier.
MIT License
714 stars 95 forks source link

It is not possible to enable feature for self closing empty tags/components #412

Open ToP29 opened 6 months ago

ToP29 commented 6 months ago

It is not possible to enable feature for self closing empty tags/components. I would like this feature back. Why not add another option to config, so user can choose if to enable it or disable it.

From readme: Whether or not empty elements/components should self-close is now left to the user - in other words, if you write

or that stays as is, and so does
/. If svelteStrictMode is turned on, it will still only allow
notation for elements (but it will leave your components alone)

dummdidumm commented 6 months ago

You can write them like that yourself, prettier won't expand the autoclosing. I therefore don't think we need an option for this