beatak / jquery-imageloader Goto Github PK
View Code? Open in Web Editor NEWjQuery.imageloader helps you to load images not on page load, and gives you call back when it's all done.
License: MIT License
jQuery.imageloader helps you to load images not on page load, and gives you call back when it's all done.
License: MIT License
Your plugin works like a charm.
The only feature I'm missing is the possibility to tell it to load images when they appears on the page, instead of loading all images continuously from DOM loading.
I tried to attach imageloader() to each image but the plugins bugged, apparently because all images were not set at the same time. Seems like it tried to create a queue for each imageloader()...
Do you have a proper way to do that ?
Thanks
Jquery ImageLoader fails one in 100 times for me. When the page loads, it does not give any error and deletes the image dom element. On reloading, it gives me the correct image though. Is there a way the error can be fixed or handled? Thanks
When using a different dataattr, the script won't work.
Fix is on line 115:
var src = $elm.data('src');
needs to be changed to:
var src = $elm.data(attr);
right now, there's no really way to switch the image source, by some client side display condition (such as high dpi etc)
let's say, there's a image gallery application. There's one big picture, and there are thumbnails. When you click on each thumbnail, the big picture changes.
In a simple implementation, there's a handler attached to the click event, that triggers imageloader() on the big picture. it works most of the case.
But If you keep clicking the thumbnails before the big picture gets loaded, and if the server returns not sequentially, the eventual result may not be the way you expect. It'd be nice, if there's a way to control the result.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.