Open markmals opened 2 years ago
This happens because we treat those context as JSX syntax (which can't have HTML comments) instead of HTML. I wonder if we'd be able to add HTML comments to the JSX syntax for this use case :thinking:
Good catch, thanks for the report!
Describe the Bug
When using an HTML comment as one of the results of an inline ternary expression in an Astro template file, Visual Studio Code with the Astro extension (version: 0.16.1) does not properly highlight it as a comment and instead highlights it as what appears to be invalid JSX. Image attached:
Steps to Reproduce
.astro
) in Visual Studio Code.{ sayHello ?
Hello, World!
: }