aaron-bond / better-comments

https://marketplace.visualstudio.com/items?itemName=aaron-bond.better-comments
MIT License
831 stars 161 forks source link

Add support to template engines #423

Open abrahamebij opened 2 years ago

abrahamebij commented 2 years ago

I'm trying to use Better Comments on an ejs file and it doesn't work, but it works in a regular HTML file.

EJS looks really similar to HTML and I'll love if you can make it compatible.

Zxynine commented 2 years ago

I'm trying to use Better Comments on an ejs file and it doesn't work, but it works in a regular HTML file.

EJS looks really similar to HTML and I'll love if you can make it compatible.

You should be able to just download an extension to get support for the ejs language and if it is set up properly, it should work from there. This extension uses the language config files from any extensions that add languages to find its comment delimiters.

Zxynine commented 2 years ago

If you already have one, then it may not be configured correctly or there is a problem with better comments. A quick look at the first extention that came up when i searched sent me to "EJS language support". Looking at their "package.json" file, they do not define a language in the contributes section despite having a "language-configuration.json" file. I would assume that is a mistake on their part and could easily be the source of the problem if that is the extension you have.