$ (documento) .Ready, window.onload

document.addEventListener("DOMContentLoaded", function(event) { 
  //do work
});

// or
window.onload = function() {

};
minh chiu