Skip to content

Commit

Permalink
Moved jQuery's domready to after the Transformie declaration to preve…
Browse files Browse the repository at this point in the history
…nt errors on instances where script is loaded after dom is ready.


It's probably a rare case but it was happening on my local dev machine while building a website and loading via Modernizr.load()...
  • Loading branch information
Hari Karam Singh committed Nov 5, 2011
1 parent 8e2d0a4 commit 57b775f
Showing 1 changed file with 17 additions and 17 deletions.
34 changes: 17 additions & 17 deletions transformie.js
@@ -1,19 +1,3 @@
jQuery(function() {

if(!jQuery.browser.msie) return;

// Parsing stylesheets, almost always makes sense
Transformie.defaults.stylesheets && Transformie.parseStylesheets();

// if we want to track inline CSS, we're resolving all inline transforms at page launch
Transformie.inlineCSS && Transformie.apply(Transformie.inlineCSS === true ? '*' : Transformie.inlineCSS);

// we have a dynamic site and we want to track inline style changes on a list of elements
Transformie.defaults.track && Transformie.track(Transformie.defaults.track);

});


var Transformie = {

defaults: {
Expand Down Expand Up @@ -194,4 +178,20 @@ var Transformie = {
return matrix;

}
};
};


jQuery(function() {

if(!jQuery.browser.msie) return;

// Parsing stylesheets, almost always makes sense
Transformie.defaults.stylesheets && Transformie.parseStylesheets();

// if we want to track inline CSS, we're resolving all inline transforms at page launch
Transformie.inlineCSS && Transformie.apply(Transformie.inlineCSS === true ? '*' : Transformie.inlineCSS);

// we have a dynamic site and we want to track inline style changes on a list of elements
Transformie.defaults.track && Transformie.track(Transformie.defaults.track);

});

0 comments on commit 57b775f

Please sign in to comment.