3

jQuery v3.0 deprecates the .load() function which has me in a bind because my jQuery scripts require that images be loaded before they run. Does anyone know a way to apply what was previously coded as

$(window).ready(function() {

but without using the .load() lead in?

$(window).ready(function() definitely does NOT work, as it triggers before the images are loaded.

I am trying to find a solution which works well with a jQuery function. I am aware of Javascript .onload but am not sure how to mesh that as a lead in for jQuery routines.

Thank you!

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Ira G
  • 133
  • 1
  • 9

1 Answers1

6

According to http://blog.jquery.com/2016/06/09/jquery-3-0-final-released/:

Removed deprecated event aliases

.load, .unload, and .error, deprecated since jQuery 1.8, are no more. Use .on() to register listeners.

https://github.com/jquery/jquery/issues/2286

j08691
  • 204,283
  • 31
  • 260
  • 272