diff --git a/HISTORY.md b/HISTORY.md index 87b1923..93a2df1 100755 --- a/HISTORY.md +++ b/HISTORY.md @@ -1,5 +1,9 @@ # Release history +## v0.2.3 + +- Changed default ttl from 3s to 15s. + ## v0.2.2 - Safer image loading: images with a wrong or missing source get a placeholder image (when used diff --git a/README.md b/README.md index 256c63f..ae92410 100755 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ imagePreloader.start(); You can provide completely optional parameters to the start method: -- `ttl`: the maximum time you want to wait on one image before having the onerror triggered (ms). Default value is 3000ms. +- `ttl`: the maximum time you want to wait on one image before having the onerror triggered (ms). Default value is 15000ms. - `maxParallel`: the maximum number of images you want to allow to be loaded in parallel (if you want to avoid something else to be blocked). Default value is 5. - `placeholderImgData`: what data image you want for failed images. Default is an empty 1x1 transparent png. diff --git a/component.json b/component.json index e692fac..8f402f8 100755 --- a/component.json +++ b/component.json @@ -1,6 +1,6 @@ { "name": "image-preloader", - "version": "0.2.2", + "version": "0.2.3", "description": "An image pre-loader component", "dependencies": { "Wizcorp/eventemitter": "*", diff --git a/index.js b/index.js index d661d67..cf466ad 100755 --- a/index.js +++ b/index.js @@ -1,7 +1,7 @@ var inherit = require('util').inherits; var EventEmitter = require('EventEmitter'); -var defaultTtl = 3000; +var defaultTtl = 15000; var defaultMaxParallel = 5; var emptyImg = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVQYV2NgYAAAAAMAAWgmWQ0AAAAASUVORK5CYII=';