theron-wang / VS2022-Editor-Support-for-Tailwind-CSS

Unofficial VS2022 Tailwind CSS extension for IntelliSense, linting, sorting, and more to enhance the development experience in Visual Studio 2022.
https://marketplace.visualstudio.com/items?itemName=TheronWang.TailwindCSSIntellisense
MIT License
86 stars 5 forks source link

[Bug] Extra apostrophe is added after saving #42

Closed hockchuanuwc closed 3 months ago

hockchuanuwc commented 3 months ago

Steps:

  1. Before saving,
    <button x-on:click="tab = 1" :class="{ 'bg-neutral-500 font-bold': tab === 1, 'bg-neutral-200': tab !== 1 }" class="inline-flex h-12 w-full items-start justify-between rounded p-4">
    Button
    </button>
  2. After saving, an extra apostrophe will be appended before 'bg-neutral-200' css name.
    <button x-on:click="tab = 1" :class="{ 'bg-neutral-500 font-bold': tab === 1, ''bg-neutral-200': tab !== 1 }" class="inline-flex h-12 w-full items-start justify-between rounded p-4">
    Button
    </button>

Extension Version: 1.3.2 Visual Studio: Microsoft Visual Studio Enterprise 2022 (64-Bit) - Current Version: 17.9.7

theron-wang commented 3 months ago

Thank you for reporting - this should now be fixed in 1.4.0. Just to confirm, was this in a .razor/.cshtml file or in a .html file? I was only able to reproduce it in a .razor file and not .html, so I wanted to make sure the issue is actually resolved.

hockchuanuwc commented 3 months ago

The issue was in .cshtml file, I didn't test in .html file. Yes, the issue is now fixed in the latest 1.4.0 version.

You can close this issue. Thank you for the speedy resolution.

theron-wang commented 3 months ago

Great, thanks.