Skip to main content

Posts

Showing posts from 2013

Please Stop the jsPerf.com Abuse!

According to many of the tests on jsperf.com , jQuery is slow. Really slow. The jQuery team gets bug reports from web citizens who've discovered these egregious flaws via jsperf and want them fixed. Now, jsperf.com can be a great tool when used knowledgeably, but its results can also be misinterpreted and abused. For example: Why doesn't jQuery use DOM classList for methods like .addClass()? There are at least three good reasons. It doesn't make any practical performance difference given its frequency of use. It complicates code paths, since classList isn't supported everywhere. It makes jQuery bigger, which makes it load slower for everyone, every time. But this jsperf shows classList is much faster! How can you say that? Well it's possible that test is running afoul of microbenchmark issues , and not measuring what it is supposed to measure due to the increased sophistication of today's JavaScript compilers. This is a big problem with a lot of t

Amazon: You Know Better

For the past few days, Amazon has followed me around the Internet with this one advertisement for a rolling suitcase. That's because the wheel bearings on my old rolling suitcase are just about shot, they're all screechy and wobbly. It's been a good suitcase and traveled over the world, but it's just worn out. So I went over and bought a nice suitcase from Amazon, using my Prime membership. But I didn't get that suitcase, I got a different one. Amazon knows perfectly well which suitcase I got, it was delivered today, and it's nicer than this one in my opinion. Yet Amazon continues to show me an ad for that suitcase as if to say, "Are you sure you made the right decision?" I imagine that the infrastructure that Amazon uses to determine what product to show is pretty awesome technically. Yet Amazon is doing significantly worse than if it just showed a random product from some category other than rolling suitcases, and they should know that. My

Tragedy of the WebKit Commons

With Opera announcing that their future products will be based on WebKit, the Internet is abuzz with discussion about what that means and whether it's a good thing. Looking at it as a jQuery developer, it's a good thing if it gets WebKit participants to fix bugs and update older implementations. I can't be optimistic without some evidence that things are really going to change. We don't know how many of Opera's core developers will move to WebKit development, but the press release isn't encouraging:  "The shift to WebKit means more of our resources can be dedicated to developing new features and the user-friendly solutions."  I suspect they want some cost savings by eliminating Presto technical staff, or -- in the most optimistic case for their employees -- refocusing existing staff on the parts outside WebKit core that make browsers different. Opera did  land their first WebKit patch  so they wanted to make a statement that they weren't gettin