HackMyResume icon indicating copy to clipboard operation
HackMyResume copied to clipboard

Update generic-helpers.js

Open deltoss opened this issue 6 years ago • 0 comments

I noticed when converting to word, it doesn't handle certain HTML entities well. It ends up displaying """ and so on.

Figured out by the time it reaches the wpml (which converts to WordProcessingML) function, the string was already escaped (although I don't know how it does that). So if you put quote (") in your resume JSON (e.g. a writing summary), it'll look like " at the START of the wpml function.

The problem is in line 386, it uses xml-escape to escape it again. So it'll end up as """, which in the end rendered on the document as """.

As such, I propose a change to ignore "&" when using xml-escape.

deltoss avatar Nov 28 '18 22:11 deltoss