diff --git a/CHANGELOG.md b/CHANGELOG.md index dcc07dfc..299d394c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,17 @@ ## Version 16 +#### 16.1.0 + +Improved speed, cleaning DOM, better working destroy, and also fixed 2 bugs. + +- Cleaning up `data` attributes from the DOM when finished using them (mainly when elements have finished loading) +- Improved `destroy` method, which now also removes lazyload's additions to the DOM elements +- Video elements are now only listening to the `loadeddata` event, no longer to `load` +- Removed constants containing strings. I thought it would produced shorter minified code, but discovered that terser expands them to strings. +- Bugfix: when lazily loading videos, the error `_poster_ is undefined` was thrown +- Bugfix: when selecting native lazy loading, the `loading` class was added without knowing whether or not the loading had started + #### 16.0.0 Functional changes: diff --git a/README.md b/README.md index c9d2fef8..97b10a21 100644 --- a/README.md +++ b/README.md @@ -144,7 +144,7 @@ Please note that the video poster can be lazily loaded too. ## 👩💻 Getting started - Script -The latest, recommended version of LazyLoad is **16.0.0**. +The latest, recommended version of LazyLoad is **16.1.0**. Quickly understand how to upgrade from a previous version reading the [practical upgrade guide](UPGRADE.md). @@ -161,14 +161,14 @@ If you prefer to load a polyfill, the regular LazyLoad behaviour is granted. The easiest way to use LazyLoad is to include the script from a CDN: ```html - + ``` Or, with the IntersectionObserver polyfill: ```html - + ``` Then, in your javascript code: @@ -201,7 +201,7 @@ Include RequireJS: Then `require` the AMD version of LazyLoad, like this: ```js -var lazyLoadAmdUrl = "https://cdn.jsdelivr.net/npm/vanilla-lazyload@16.0.0/dist/lazyload.amd.min.js"; +var lazyLoadAmdUrl = "https://cdn.jsdelivr.net/npm/vanilla-lazyload@16.1.0/dist/lazyload.amd.min.js"; var polyfillAmdUrl = "https://cdn.jsdelivr.net/npm/intersection-observer-amd@2.0.1/intersection-observer-amd.js"; /// Dynamically define the dependencies @@ -247,7 +247,7 @@ Then include the script. ```html ``` @@ -280,7 +280,7 @@ Then include the script. ```html ``` diff --git a/currentFeature.md b/currentFeature.md index 69b5150d..fc898f8a 100644 --- a/currentFeature.md +++ b/currentFeature.md @@ -1,2 +1 @@ -# Current feature: ___ - +# Current feature: diff --git a/demos/cancel_on_exit.html b/demos/cancel_on_exit.html index e86fceb3..666bd625 100644 --- a/demos/cancel_on_exit.html +++ b/demos/cancel_on_exit.html @@ -86,37 +86,6 @@