There are a lot of chars converted to HTML entities in input parameters.
To use it, I need to convert the HTML entities to chars to make it readable.
How I can do it in JavaScript (interesting in be-directional convertion)?
examples:
html-code | char
-----------------
a | a
&? Are you in a browser, or in node? There is nowhere near enough information to accurately answer this.fromCharCodeto decode HTML entities is wrong in the general case. Some characters happen to encode to&<ascii charcter code>;but many do not.DOMParserwould be better in case all entities need to be supported.