Open
Description
What version of prettier-plugin-tailwindcss
are you using?
v0.6.5
What version of Tailwind CSS are you using?
v3.4.4
What version of Node.js are you using?
v20.10.0
What package manager are you using?
npm
What operating system are you using?
macOS
Reproduction URL
https://github.com/madisonbullard/prettier-plugin-tailwind-bug
Describe your issue
Beginning with v0.6.0, formatting src/routes/+page.svelte
(via npm format
or format-on-save) results in syntax errors.
Before formatting
<div
class={'relative flex items-center rounded-full border border-gray-200 bg-gray-100 text-gray-500 shadow-sm transition-colors ' +
true
? `border-yellow-300 bg-yellow-200 text-yellow-700
hover:border-yellow-200 hover:bg-yellow-100
focus:border-yellow-200 focus:bg-yellow-100
active:border-yellow-50 active:bg-yellow-50`
: `hover:border-gray-100 hover:bg-gray-50 hover:text-gray-700
focus:border-gray-100 focus:bg-gray-50 focus:text-gray-700
active:border-gray-50 active:bg-white active:text-gray-300`}
>
<button class="flex min-h-5 min-w-5 items-center justify-center rounded-full" aria-label="Menu">
hi
</button>
</div>
After formatting
<div
class={'relative flex items-center rounded-full border border-gray-200 bg-gray-100 text-gray-500 shadow-sm transition-colors ' +
true
? `border-yellow-300 bg-yellow-200 text-yellow-700 hover:border-yellow-200 hover:bg-yellow-100 focus:border-yellow-200 focus:bg-yellow-100 active:border-yellow-50 active:bg-yellow-50`
: `hover:border-gray-100 hover:bg-gray-50 hover:text-gray-700 focus:border-gray-100 focus:bg-gray-50 focus:text-gray-700 active:border-gray-50 active:bg-white active:text-gray-300`}
>
<button class="flex min-h-5 min-w-5 items}
>
<button class="flex min-h-5 min-w-5 items-center justify-center rounded-full" aria-label="Menu">
hi
</button>
</div>
Metadata
Metadata
Assignees
Labels
No labels