Ask coding questions

← Back to all posts
What is the shortcut for commenting in HTML
[deleted]

Hey there, I really hate having to do the commenting in HTML, it takes forever, is there a shortcut on repl.it? Wherer I can just do something like <! (enter) or something else wherer it would make a comment for me?

Answered by SameeraMurthy (110) [earned 5 cycles]
View Answer
Comments
hotnewtop
SameeraMurthy (110)

That is the only way. Unless..

<!-- --> is the only way to comment in HTML.

Unless you use JavaScript to replace specific stuff using regexp, (which means you can make your own way of commenting!)

Or, if you don't want to do that, you can do this trick in VScode or replit:
You can do ctrl + / to comment lines, or select the specific text you want to comment and press ctrl + /.

IOP3 (854)

I don't think so, i think the only way is <!-- and -->

MunnaChaudhary (0)

Download the complete solutions of class 12th NCERT physics solutions in free of cost.
https://fullncertsolutions.in/category/class-12-physics/

RYANTADIPARTHI (6017)

Solution

the only way you can comment is <!-- -->. But if you mean comment whatever you want quickly, the easiest way is to do cntrl + /. just highlight whatever code you want commented, and do cntrl + /.

like that.
That should work

Squirrel777 (139)

Unfortunately, that is the only way that you can comment in HTML.