Comparing version 3.0.1 to 3.0.2
(function (root, factory) {(typeof module === 'object' && module.exports) ? module.exports = factory() : root.ItMap = factory()}(typeof self !== 'undefined' ? self : this, function () { | ||
"use strict";var ItMap=(()=>{var l=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var y=Object.getOwnPropertyNames;var c=Object.prototype.hasOwnProperty;var p=(t,n)=>{for(var e in n)l(t,e,{get:n[e],enumerable:!0})},m=(t,n,e,r)=>{if(n&&typeof n=="object"||typeof n=="function")for(let o of y(n))!c.call(t,o)&&o!==e&&l(t,o,{get:()=>n[o],enumerable:!(r=s(n,o))||r.enumerable});return t};var b=t=>m(l({},"__esModule",{value:!0}),t);var v={};p(v,{default:()=>S});function d(t){let[n,e]=t[Symbol.asyncIterator]!=null?[t[Symbol.asyncIterator](),Symbol.asyncIterator]:[t[Symbol.iterator](),Symbol.iterator],r=[];return{peek:()=>n.next(),push:o=>{r.push(o)},next:()=>r.length>0?{done:!1,value:r.shift()}:n.next(),[e](){return this}}}var u=d;function h(t){return t[Symbol.asyncIterator]!=null}function x(t,n){if(h(t))return async function*(){for await(let a of t)yield n(a)}();let e=u(t),{value:r,done:o}=e.next();if(o===!0)return function*(){}();let i=n(r);if(typeof i.then=="function")return async function*(){yield await i;for await(let a of e)yield n(a)}();let f=n;return function*(){for(let a of t)yield f(a)}()}var S=x;return b(v);})(); | ||
"use strict";var ItMap=(()=>{var i=Object.defineProperty;var s=Object.getOwnPropertyDescriptor;var y=Object.getOwnPropertyNames;var c=Object.prototype.hasOwnProperty;var p=(t,n)=>{for(var e in n)i(t,e,{get:n[e],enumerable:!0})},m=(t,n,e,r)=>{if(n&&typeof n=="object"||typeof n=="function")for(let o of y(n))!c.call(t,o)&&o!==e&&i(t,o,{get:()=>n[o],enumerable:!(r=s(n,o))||r.enumerable});return t};var d=t=>m(i({},"__esModule",{value:!0}),t);var v={};p(v,{default:()=>S});function b(t){let[n,e]=t[Symbol.asyncIterator]!=null?[t[Symbol.asyncIterator](),Symbol.asyncIterator]:[t[Symbol.iterator](),Symbol.iterator],r=[];return{peek:()=>n.next(),push:o=>{r.push(o)},next:()=>r.length>0?{done:!1,value:r.shift()}:n.next(),[e](){return this}}}var u=b;function h(t){return t[Symbol.asyncIterator]!=null}function x(t,n){if(h(t))return async function*(){for await(let a of t)yield n(a)}();let e=u(t),{value:r,done:o}=e.next();if(o===!0)return function*(){}();let l=n(r);if(typeof l.then=="function")return async function*(){yield await l;for await(let a of e)yield n(a)}();let f=n;return function*(){yield l;for(let a of e)yield f(a)}()}var S=x;return d(v);})(); | ||
return ItMap})); |
@@ -31,3 +31,4 @@ import peek from 'it-peekable'; | ||
return (function* () { | ||
for (const val of source) { | ||
yield res; | ||
for (const val of peekable) { | ||
yield fn(val); | ||
@@ -34,0 +35,0 @@ } |
{ | ||
"name": "it-map", | ||
"version": "3.0.1", | ||
"version": "3.0.2", | ||
"description": "Maps the values yielded by an async iterator", | ||
@@ -138,3 +138,4 @@ "author": "Alex Potsides <alex@achingbrain.net>", | ||
"devDependencies": { | ||
"aegir": "^38.1.7" | ||
"aegir": "^38.1.7", | ||
"it-all": "^3.0.0" | ||
}, | ||
@@ -141,0 +142,0 @@ "dependencies": { |
@@ -47,3 +47,5 @@ import peek from 'it-peekable' | ||
return (function * () { | ||
for (const val of source) { | ||
yield res as O | ||
for (const val of peekable) { | ||
yield fn(val) | ||
@@ -50,0 +52,0 @@ } |
Sorry, the diff of this file is not supported yet
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
11776
96
2