how to workin event on onload in javascript code example Example: js document onload //use window.onload=()=>{};