beautifier/js-beautify
Beautification problem with JS Single Line Comment <!--
Offen
#1.835 geöffnet am 31.08.2020
good first issuelanguage: javascripttype: bug
Repository-Metriken
- Stars
- (8.342 Sterne)
- PR-Merge-Metriken
- (PR-Metriken ausstehend)
Beschreibung
In Javascript <!-- is treated as a single-line comment just like //.
js-beautify works as expected when the line starts with <!--:
Input:
<!--alert(1)commented
Output:
<!--alert(1)commented
Otherwise it will break the syntax:
Input:
alert(1)<!--commented
Output:
alert(1) < !--commented