You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What I did:
I am editing a normal HTML file, which is not a template.
I press CTRL-/ to create a comment.
As a result, I get a Tera comment, not a HTML comment. This is bad.
I look at the langauge in VSCode, and it is "HTML".
My problems:
The langauge in VSCode shows "HTML".
It is not possible to choose "Vanilla HTML", as now Tera HTML claims the "HTML" language in the language chooser. The only option is to disable the whole Tera extension.
Solutions I recommend:
Do not touch the "HTML" language option in the language picker, and instead add a "HTML (Tera)" language option.
Make the "HTML (Tera)" language option auto-activate only when the file extension is foo.html.tera or something like that.
Would be cool, thanks for making this extension :).
The text was updated successfully, but these errors were encountered:
An alternative viewpoint: please do not change the current behavior of the extension (or, if you do make this change, please allow the user to disable it and use the old behavior).
Here's why:
In VSCode, templating languages that aren't built-in to the editor do not have all the intellisense and auto-formatting features present in the HTML language type. This is a longstanding issue with the editor, and does not seem to be a high priority for the team to fix. See: microsoft/vscode#41066, microsoft/vscode#53462
Although Emmet can be enabled for alternative templating languages, hover documentation and automatic formatting (for example, pressing "enter" between two tags to get an added newline and proper indentation) do not work. Try this out in any other templating extension with its own filetype to see what I mean (Better Jinja, ERB, etc).
The choice to extend the HTML language instead of creating a new language type is shared with a popular Hugo extension, and I think it's the correct decision. If you want to use HTML-style comments (for example, while working on plain HTML files), you could just disable the Tera extension temporarily.
If I have to choose between using HTML-style comments and using intellisense and automatic indentation, I would much rather choose the latter!
A bit related to issue #15.
What I did:
I am editing a normal HTML file, which is not a template.
I press
CTRL-/
to create a comment.As a result, I get a Tera comment, not a HTML comment. This is bad.
I look at the langauge in VSCode, and it is "HTML".
My problems:
Solutions I recommend:
foo.html.tera
or something like that.Would be cool, thanks for making this extension :).
The text was updated successfully, but these errors were encountered: