Monday, 3 June 2013

General - CSS JS Order Optimization

script.js
var i, total=0;
for (i=1;i<=3000;i++){
    total += Math.sqrt(2 * Math.pow(i, 2));;
    document.write("Total: " + total);
    document.write("<br>");
}
CSS then JS

JS then CSS

CSS, JS, CSS then JS

JS, CSS, JS then CSS

*In Most Cases, CSS FirstJS Second

More Info: 

No comments :

Post a Comment