HTML Entities are unescaped when creating using json object
chris-rudmin opened this issue · 1 comments
chris-rudmin commented
Describe the bug
HTML Entities are unescaped when creating xml using a json object
To Reproduce
create().ele({
'foo': ''"©℗™'
}).end()
// <?xml version="1.0"?><foo>'"©℗™</foo>
create().ele('foo').txt(''"©℗™').end()
// <?xml version="1.0"?><foo>'"©℗™</foo>
Expected behavior
text should remain as it was input and should be consistent with the chained builder
Version:
- node.js: [14.18.1]
- xmlbuilder2 [3.0.2]
Additional context
universalhandle commented