Skip to main content
<body onload="myFunction()">

This code works well.

butBut window.onload havemethod has various dependencies. soSo it may not work all the time.

<body onload="myFunction()">

This code works well.

but window.onload have various dependencies. so it may not work all the time

<body onload="myFunction()">

This code works well.

But window.onload method has various dependencies. So it may not work all the time.

Source Link
Akarsh Satija
  • 1.8k
  • 2
  • 22
  • 28

<body onload="myFunction()">

This code works well.

but window.onload have various dependencies. so it may not work all the time