On 12/7/13 5:37 PM, Domenic Denicola wrote:
$(document.querySelector(".my-slider")).slider("option", "disabled", false);

instead of

document.querySelector(".my-slider").disabled = false;

I should note that the latter is _much_ more likely to be fast, for people who care about that sort of thin. In particular, it's much more likely to be simple straight line code that operates on monomorphic types than the former; the former is more likely to end up in some sort of generic dispatch framework that ends up with polymorphic code to boot.

So it's much more likely that a JIT can usefully inline the latter and compile it to just a few instructions than it is that it can do that with the former...

-Boris

Reply via email to