Relawan kami belum menerjemahkan artikel ini ke bahasa Bahasa Indonesia. Bergabunglah dan bantu kami menyelesaikannya!
Anda juga dapat membaca artikel ini dalam English (US).

The onloadend property of the GlobalEventHandlers mixin is an EventHandler representing the code to be called when the loadend event is raised (when progress has stopped on the loading of a resource.)

Syntax

img.onloadend = funcRef;

Value

funcRef is the handler function to be called when the resource's loadend event fires.

Examples

HTML content

<img src="myImage.jpg">

JavaScript content

// 'loadstart' fires first, then 'load', then 'loadend'

image.addEventListener('load', function(e) {
  console.log('Image loaded');
});

image.addEventListener('loadstart', function(e) {
  console.log('Image load started');
});

image.addEventListener('loadend', function(e) {
  console.log('Image load finished');
});

Specifications

Specification Status Comment
HTML Living Standard
The definition of 'onloadend' in that specification.
Living Standard Initial definition

Browser compatibility

FeatureChromeEdgeFirefoxInternet ExplorerOperaSafari
Basic support No No52 No No ?
FeatureAndroid webviewChrome for AndroidEdge mobileFirefox for AndroidOpera AndroidiOS SafariSamsung Internet
Basic support No No No52 No ? ?

Tag Dokumen dan Kontributor

Kontributor untuk laman ini: fscholz, Sebastianz, chrisdavidmills
Terakhir diperbarui oleh: fscholz,