Instantly share code, notes, and snippets.

Embed
What would you like to do?
Dump all document.styleSheets[*].cssRules[*].cssText to console
// Dump all document.styleSheets[*].cssRules[*].cssText to console:
(function(s,c,r,i,j){ for(i=0;i<s.length;i++){c=s[i].cssRules;for(j=0;j<c.length;j++){r=c[j].cssText;console.log('document.styleSheets['+i+'].cssRules['+j+'].cssText = "'+r+'";')}} })(document.styleSheets);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment