I have a simple CSS3
fade in page transition, which works well (ONLY care about IE10+). Here's what it looks like:
HEAD
body
{
opacity: 0;
transition: all 1s ease;
}
.loaded
{
opacity:1;
}
BODY
<body onload="document.body.classList.add('loaded');">
The only problem now, is that if the page has a lot of images, the onload event is triggered only when all of them are downloaded.
What can I do, using pure javascript or CSS to do the fade in, even while images are downloading?
NOTE: Can't use any external js files or frameworks.