Closed nwah closed 8 years ago
Nice catch, thank you.
Merged, thank you! This will be in v0.12, releasing momentarily.
Surprisingly, the regex you provided failed on IE 11 (but not IE 8 or Edge). I replaced it with String.trim(), plus a shim for IE 8.
Hey @jamesshore,
This PR just strips leading / trailing whitespace from
html
passing intoframe.add()
before assigning it totempElement.innerHTML
.I just discovered Quixote and am very excited about it, but when I just tried to write my first test, doing something like this:
I got this error:
It seems like when doing
tempElement.innerHTML = html
(here), it's creating text nodes with the whitespace, which makes the subsequent check for only 1 childNode fail.