We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
This looks to be a very similar issue to #205.
The following works as a minimum repro in Svelte for VS Code v107.10.0
<div> <!-- this is duplicated on format --> <style></style> </div>
But both of the following work as expected
<div> <!-- this is *not* duplicated on format --> <p>Hi</p> </div>
<!-- this is *not* duplicated on format --> <style></style>
So it appears to be the combination of the <style> tag and nested structure that triggers the bug.
<style>
The text was updated successfully, but these errors were encountered:
I'm seeing this as well, but with a comment preceding a <script> tag rather than a <style> tag.
<script>
Interestingly, it only happens when that <script> tag exists within a <svelte:head> tag, like so:
<svelte:head>
<svelte:head> <!-- Fathom Analytics --> <script src="https://xxx.alexlafroscia.com/script.js" data-site="xxx" data-spa="auto" defer ></script> </svelte:head>
The <!-- Fathom Analytics --> line is repeated each time Prettier formats the file
<!-- Fathom Analytics -->
Sorry, something went wrong.
fix: don't duplicate comments of nested script/style tags
64abd62
fixes #400
fix: don't duplicate comments of nested script/style tags (#425)
cc856a0
Successfully merging a pull request may close this issue.
This looks to be a very similar issue to #205.
The following works as a minimum repro in Svelte for VS Code v107.10.0
But both of the following work as expected
So it appears to be the combination of the
<style>
tag and nested structure that triggers the bug.The text was updated successfully, but these errors were encountered: