modernizr
Version:
Modernizr is a JavaScript library that detects HTML5 and CSS3 features in the user’s browser.
19 lines (18 loc) • 470 B
JavaScript
/*!
{
"name": "will-change",
"property": "willchange",
"caniuse": "will-change",
"notes": [{
"name": "W3C Spec",
"href": "https://drafts.csswg.org/css-will-change/"
}]
}
!*/
/* DOC
Detects support for the `will-change` css property, which formally signals to the
browser that an element will be animating.
*/
define(['Modernizr', 'docElement'], function(Modernizr, docElement) {
Modernizr.addTest('willchange', 'willChange' in docElement.style);
});