Comparing version 0.0.5 to 0.0.6
@@ -1,1 +0,1 @@ | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e():"function"==typeof define&&define.amd?define(e):e()}(this,function(){"use strict";function t(t,e,n){return t.length?Array.from(t,function(t){setTimeout(function(){t.classList.add(e)},n)}):setTimeout(function(){t.classList.add(e)},n),this}exports.lazy=t}); | ||
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e():"function"==typeof define&&define.amd?define(e):e()}(this,function(){"use strict";function t(t,e,n){return t.length?Array.from(t,function(t){setTimeout(function(){t.classList.add(e)},n)}):setTimeout(function(){t.classList.add(e)},n),this}exports.lazy=t});!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n():"function"==typeof define&&define.amd?define(n):n()}(this,function(){"use strict";function t(t,n,e){var i=function(t){setTimeout(function(){t.classList.add(n)},e)};return t.length?Array.from(t,function(t){i(t)}):i(t),this}exports.lazy=t});!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n():"function"==typeof define&&define.amd?define(n):n()}(this,function(){"use strict";function t(t,n,e){var i=function(t){setTimeout(function(){t.classList.add(n)},e)};return t.length?Array.from(t,function(t){i(t)}):i(t),this}exports.lazy=t});!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n():"function"==typeof define&&define.amd?define(n):n()}(this,function(){"use strict";function t(t,n,e){var i=function(t){setTimeout(function(){t.classList.add(n)},e)};return t.length?Array.from(t,function(t){i(t)}):i(t),this}exports.lazy=t});!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n():"function"==typeof define&&define.amd?define(n):n()}(this,function(){"use strict";function t(t,n,e){var i=function(t){setTimeout(function(){t.classList.add(n)},e)};return t.length?Array.from(t,function(t){i(t)}):i(t),this}exports.lazy=t}); |
{ | ||
"name": "bradpitt", | ||
"version": "0.0.5", | ||
"version": "0.0.6", | ||
"description": "Set of javascript modules that do cool stuff", | ||
@@ -5,0 +5,0 @@ "main": "dist/bradpitt.min.js", |
@@ -16,7 +16,6 @@ ## Bradpitt.js | ||
## Initialize BradPitt | ||
## Initialize BradPitt Modules | ||
```javascript | ||
import BradPitt from 'bradpitt' | ||
const bradpitt = new BradPitt() | ||
import {lazy} from 'bradpitt' | ||
``` | ||
@@ -33,5 +32,5 @@ | ||
bradpitt.lazy(oscar, 'won', 600) | ||
lazy(oscar, 'won', 600) | ||
bradpitt.lazy(oscars, 'nominated', 900) | ||
lazy(oscars, 'nominated', 900) | ||
``` | ||
@@ -38,0 +37,0 @@ |
@@ -11,14 +11,6 @@ | ||
function lazy(el, className, timing) { | ||
if (el.length) { | ||
Array.from(el, (e) => { | ||
setTimeout(() => { | ||
e.classList.add(className) | ||
}, timing) | ||
}) | ||
} else { | ||
setTimeout(() => { | ||
el.classList.add(className) | ||
}, timing) | ||
let sT = (e) => { | ||
setTimeout(() => { e.classList.add(className) }, timing) | ||
} | ||
el.length ? Array.from(el, (e) => { sT(e) }) : sT(el) | ||
return this | ||
@@ -25,0 +17,0 @@ } |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11539
111
38