← back to articles

dinbror/blazy

Save article ToRead Archive Delete · Log out

4 min read · View original · github.com

hey, be lazy

bLazy is a lightweight script for lazy loading and multi-serving images (less than 1.2KB minified and gzipped). It’s written in pure JavaScript why it doesn’t depend on 3rd-party libraries such as jQuery. It lets you lazy load and multi-serve your images so you can save bandwidth and server requests. The user will have faster load times and save data usage if he/she doesn't browse the whole page.

Table of Contents
1. Demo
2. Usage & API
3. Why be lazy?
4. Changelog
5. License

DEMO

http://dinbror.dk/blazy

More examples will come. In the meantime you can play with a basic example at codepen: http://codepen.io/dinbror/pen/HzCAJ

USAGE & API

http://dinbror.dk/blog/blazy

INSTALL

You can install blazy.js with npm:

npm install blazy --save

or bower:

bower install blazy --save

CDN

If you don't want to host the script yourself you can link to the latest minified file:
//cdn.jsdelivr.net/blazy/latest/blazy.min.js on jsDelivr. Exchange latest with the specific version number if you want to lock it in.

WHY BE LAZY?

CHANGELOG

v 1.5.2 (2015/12/01)

v 1.5.1 (2015/11/14)

v 1.5.0 (2015/10/30)

v 1.4.1 (2015/10/12)

v 1.4.0 (2015/09/28)

v 1.3.1 (2015/02/01)

v 1.3.0 (2015/01/23)

v 1.2.2 (2014/05/04)

v 1.2.1 (2014/03/23)

v 1.2.0 (2014/02/15)

v 1.1.3 (2014/01/21)

v 1.1.2 (2014/01/03)

v 1.1.1 (2013/12/27)

v 1.1.0 (2013/11/22)

v 1.0.5 (2013/10/7)

v 1.0.4 (2013/8/29)

v 1.0.3 (2013/8/27)

v 1.0.2 (2013/8/7)

v 1.0.1 (2013/8/6)

LICENSE:

Copyright (c) 2013-15 Bjørn Klinggaard. Licensed under the The MIT License (MIT).