W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2015

Re: oldNode.replaceWith(...collection) edge case

From: Boris Zbarsky <bzbarsky@mit.edu>
Date: Wed, 21 Jan 2015 07:21:48 -0500
Message-ID: <54BF99DC.5000807@mit.edu>
To: public-webapps@w3.org
On 1/21/15 3:52 AM, Simon Pieters wrote:
> This jsperf might be interesting:
>
> http://jsperf.com/appendchild-vs-documentfragment-vs-innerhtml/81

Or misleading.

Again, in real life what matters most here is what else is on the page, 
which the jsperf doesn't capture.  The other thing that really matters 
is how many elements are being inserted, exactly, of course... which the 
jsperf also doesn't capture.

Typically, jsperf is the wrong tool for answering questions like this, 
unless you're 100% sure your microbenchmark captures all the essential 
features of the macro-situation...

-Boris
Received on Wednesday, 21 January 2015 12:22:18 UTC

This archive was generated by hypermail 2.3.1 : Friday, 27 October 2017 07:27:25 UTC