Хабр Курсы для всех
РЕКЛАМА
Практикум, Хекслет, SkyPro, авторские курсы — собрали всех и попросили скидки. Осталось выбрать!
HTML 5 data- attributes will be automatically pulled in to jQuery’s data object.
For example, given the following HTML:
<div data-role="page" data-hidden="true" data-options='{"name":"John"}'></div>
All of the following jQuery code will work.
$("div").data("role") === "page"; $("div").data("hidden") === true; $("div").data("options").name === "John";
Note that strings are left intact while Javascript values are converted to their associated value (this includes booleans, numbers, objects, arrays, and null).
Вышел jQuery 1.4.3