You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jan 4, 2018. It is now read-only.
Browsers seem to consistently report outerHTML / innerHTML between vendors but have odd behaviour when inspecting the values. For example:
constdiv=document.createElement('div');div.innerHTML='<div test=""test1 & test2"">"test1 & test2"</div>';console.log(div.outerHTML);console.log(div.innerHTML);console.log(div.getAttribute('test');console.log(div.firstChild.outerHTML);console.log(div.firstChild.innerHTML);console.log(div.firstChild.getAttribute('test');
To be consistent with their inconsistencies, we need to make outerHTML encode the values that it uses to serialise the attributes using node.value.
The text was updated successfully, but these errors were encountered:
Browsers seem to consistently report outerHTML / innerHTML between vendors but have odd behaviour when inspecting the values. For example:
To be consistent with their inconsistencies, we need to make
outerHTML
encode the values that it uses to serialise the attributes usingnode.value
.The text was updated successfully, but these errors were encountered: