Skip to content
Permalink
Browse files
Use window.getComputedStyle to prevent breaking jsdom/node.js . Fixes…
… #12235
  • Loading branch information
rwaldron committed Aug 10, 2012
1 parent 77412e0 commit 3722aef
Showing 1 changed file with 2 additions and 2 deletions.
@@ -279,11 +279,11 @@ jQuery.extend({
});

// NOTE: To any future maintainer, we've used both window.getComputedStyle

This comment has been minimized.

Copy link
@staabm

staabm Aug 11, 2012

Contributor

As of now the Comment is bogus

// and getComputedStyle here to produce a better gzip size
// because jsdom on node.js will break without it.
if ( window.getComputedStyle ) {
curCSS = function( elem, name ) {
var ret, width, minWidth, maxWidth,
computed = getComputedStyle( elem, null ),
computed = window.getComputedStyle( elem, null ),
style = elem.style;

if ( computed ) {

0 comments on commit 3722aef

Please sign in to comment.