Page fully re-rendered event?
Posted
by alex
on Stack Overflow
See other posts from Stack Overflow
or by alex
Published on 2010-05-13T03:08:08Z
Indexed on
2010/05/13
3:44 UTC
Read the original article
Hit count: 204
JavaScript
|webkit
I'm altering the DOM tree in plain JS and need to know when the changes get fully rendered on screen (mostly care about document dimensions).
window.onload=function(){
ss = document.styleSheets[0];
for(i = 0; i < ss.cssRules.length; i++) { ss.deleteRule(i) };
ss.addRule('p', 'color: red;')
// ... many more
// call some other function when the page is fully rendered?
}
TIA.
© Stack Overflow or respective owner