Dom pronto JS
document.addEventListener("DOMContentLoaded", function() {
// code
});
Joyous Jaguar
document.addEventListener("DOMContentLoaded", function() {
// code
});
document.addEventListener("DOMContentLoaded", function(event) {
//do work
});
// Pure JS document ready ...
document.addEventListener('DOMContentLoaded', (event) => {
//the event occurred
})
document.addEventListener("DOMContentLoaded", function(event) {
//we ready baby
});
// without jQuery (doesn't work in older IEs)
document.addEventListener('DOMContentLoaded', function(){
// your code goes here
}, false);
window.onload = function() {
};