pushqrdx / vscode-inline-html

🎨 Adding Syntax Highlighting, Emmet, IntelliSense support for ES6 Template Strings in Visual Studio Code.
https://marketplace.visualstudio.com/items?itemName=pushqrdx.inline-html
GNU General Public License v3.0
54 stars 15 forks source link

Bug: wrong comment syntax inside <style> tags #27

Open dev-nicolaos opened 2 years ago

dev-nicolaos commented 2 years ago

Environment Observed In

Extension version: v0.3.5 VS Code version: 1.69.1 OS: Windows 11

Steps to reproduce

Expected Behavior

The editor adds the sequence /* */ (CSS comment) in place as it does when you execute the same command inside a <style> tag in an HTML file.

Observed Behavior

The editor adds the sequence <!-- --> (HTML comment) in place.

pushqrdx commented 2 years ago

@dev-nicolaos yeah i know about this issue although i haven't figured out exactly why does vscode do this, because the html language server is able to understand the <style> blocks in normal html files.

conor-dowdall commented 9 months ago

As a workaround, you can bind the command "Emmet: Toggle Comment" to a keyboard shortcut (maybe Ctrl + Shift + /) and use that to comment HTML and/or CSS in a template string.