lazyload
lazyload copied to clipboard
implement callback function feature
What's this PR do?
add callback function.
When the image is loaded, the function defined as 'onLoadCallback' is called.
lazyload(null, {
onLoadCallback: function() {
console.log('callback function is called!');
}
});
Related Issues
#389
I'm new to this. Is this correct? Please review in your free time. 😄
+1
Seems to be here: https://github.com/tuupola/lazyload/pull/429/commits (not added to the core yet)
File: https://github.com/tuupola/lazyload/blob/2a4fbfc0b702057338724f8ed2cd09c7db17f403/lazyload.js
Further, see here: https://stackoverflow.com/q/11398005/1066234
And with version 1.x: https://github.com/tuupola/lazyload/issues/246 - File: https://github.com/tuupola/lazyload/blob/1.x/jquery.lazyload.js