jQuery 1.4 Released
I’m a bit late to blog this, but better late than never.
Since I’m a big fan of jQuery I felt I should at least plug their new release and you can find it at jquery14.com
The code has been heavily re-factored to improve performance and reduce it’s overall complexity. Day One took the opportunity to show off some fancy bar charts of it’s speed improvements. The uncompressed file is 156KB and the minified file is a 23KB(gzipped).
They also announced they closed 207 bugs. Which as a developer is impressive because we all are petty lazy, amirite? Ok bad humour aside, 207 is an impressive number to me.
Some cool features that stuck out to me where easier setter functions:
// find all ampersands in A's and wrap with a span
$('a').html(function(i,html){
return html.replace(/&/gi,'<span class="amp">&</span>');
});
attr() was a setter method that could take a function as an argument. Now that feature has been given to all the setter methods. (.css(), .attr(), .val(), .html(), .text(), .append(), .prepend(), .before(), .after(), .replaceWith(), .wrap(), .wrapInner(), .offset(), .addClass(), .removeClass(), and .toggleClass()).
Some of the standout speed performance improvements are that .html() performance now runs 3 times as fast, .remove() and .empty() are now 4 times as fast. Also notable improvements are made on .append(), .prepend(), .before(), and .after().
More information about jQuery 1.4 and it’s new features can be found at the jQuery 1.4 API page.








![Validate my RSS feed [Valid RSS]](http://www.unemployeddeveloper.com/wp-content/themes/ud2/images/valid-rss.png)