Wrapping html may encode html attributes

wrapHTML has to encode attribute values:
{ "data-content": "my \"encoded\" content" }

has to be converted to:
data-content="my &amp;quot;encoded&amp;quot; content"