Home jQuery 1.8 goes Beta and Grunts Custom Versions

jQuery 1.8 goes Beta and Grunts Custom Versions


Customisation is key to the just announced beta 1.8 version of the jQuery JavaScript library. It is now possible to exclude modules from jQuery using a new build system based on grunt; this allows developers to drop modules for ajax, css, dimensions, effects or offset, depending on what their web application actually needs, reducing the amount of jQuery code downloaded to the browser. With all those modules excluded, jQuery is a lean 21KB (minified and gzipped), but the developers stress this is an optional process and they will continue distributing the complete library through content delivery networks. Details of the build system are available in the README file.
jQuery 1.8 beta also aims to ease the pain of vendor prefixes for CSS features that aren’t yet standardised by automatically expanding property names for the current browser through the .css() function. A cleanup and rework of the animation engine has been so extensive, that there are now new extension points that should make it easier to add or modify animations, but documentation is currently sparse. The Sizzle CSS selector engine has also had a major rewrite resulting in a “widespread performance improvement”, enhanced shortcuts and better handing of more edge cases and browser bugs.
The developers are also warning that in jQuery 1.9, the version after 1.8, they will be tightening up on the HTML taken by the $() function. This is because cross site scripting attacks could make use of the behaviour of the function to execute code in <script> tags. jQuery will become more careful about what it accepts as HTML code within $(), only allowing strings which start with “<” to be regarded as such. Preceding that tightening, jQuery 1.8 has a new method, $.parseHTML which lets the system turn strings into HTML and parse HTML into DOM fragments.
jQuery 1.8 beta also marks the removal or deprecation of a number of “trip hazards” including $.browser browser detection, $.sub which failed to be useful or robust enough and global ajax events which had become an inefficient special case. Full details of the changes in jQuery 1.8 beta 1 can be found at the end of the announcement. The MIT or GPLv2 licensed jQuery 1.8 beta 1 can be downloadedDirect download and the source is available from the project’s Github repository.
Source The H Open

About ReadWrite’s Editorial Process

The ReadWrite Editorial policy involves closely monitoring the tech industry for major developments, new product launches, AI breakthroughs, video game releases and other newsworthy events. Editors assign relevant stories to staff writers or freelance contributors with expertise in each particular topic area. Before publication, articles go through a rigorous round of editing for accuracy, clarity, and to ensure adherence to ReadWrite's style guidelines.

Get the biggest tech headlines of the day delivered to your inbox

    By signing up, you agree to our Terms and Privacy Policy. Unsubscribe anytime.

    Tech News

    Explore the latest in tech with our Tech News. We cut through the noise for concise, relevant updates, keeping you informed about the rapidly evolving tech landscape with curated content that separates signal from noise.

    In-Depth Tech Stories

    Explore tech impact in In-Depth Stories. Narrative data journalism offers comprehensive analyses, revealing stories behind data. Understand industry trends for a deeper perspective on tech's intricate relationships with society.

    Expert Reviews

    Empower decisions with Expert Reviews, merging industry expertise and insightful analysis. Delve into tech intricacies, get the best deals, and stay ahead with our trustworthy guide to navigating the ever-changing tech market.