jQuery event for images loaded

后端 未结 14 1431
离开以前
离开以前 2020-11-22 15:25

Is it possible to detect when all images are loaded via a jQuery event?

Ideally, there should be a

$(document).idle(function()
{
}

14条回答
  •  不要未来只要你来
    2020-11-22 15:42

    window.load = function(){}

    Its fully supported by all browsers, and it will fire an event when all images are fully loaded.

    https://developer.mozilla.org/en-US/docs/Web/API/GlobalEventHandlers/onload

提交回复
热议问题