Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rambda

Package Overview
Dependencies
Maintainers
1
Versions
203
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rambda - npm Package Compare versions

Comparing version 0.7.0 to 0.7.1

__tests__/reduce.js

8

__tests__/compose.js

@@ -5,4 +5,10 @@ const R = require("../rambda")

it("", () => {
expect(() => { R.compose(3, [ 1, 2, 3 ]) }).toThrow()
const result = R.compose(
R.last,
R.map(R.add(10)),
R.map(R.add(1))
)([1,2,3])
expect(result).toEqual(14)
})
})
const R = require("../rambda")
describe("path", () => {
it("works with string instead of array", () => {
expect(
R.path(
"foo.bar.baz"
)({ foo : { bar : { baz : "yes" } } })
).toEqual("yes")
})
it("", () => {

@@ -5,0 +12,0 @@ expect(

@@ -51,2 +51,4 @@ [![Build Status](https://img.shields.io/travis/selfrefactor/rambda.svg)](https://travis-ci.org/selfrefactor/rambda)

- Rambda's **path** accepts both string and array as object path.
- **Rambda** is tested for compatability with **Ramda.flip**, as this method could be useful in some cases.

@@ -95,2 +97,15 @@

#### compose
> compose(fn1: Function, ... , fnN: Function): any
Performs right-to-left function composition
```
const result = R.compose(
R.map(a => a*2)
R.filter(val => val>2),
)([1, 2, 3, 4])
console.log(result) // => [6, 8]
```
#### contains

@@ -328,3 +343,3 @@

> path(pathToSearch: Array<String>, obj: Object): any
> path(pathToSearch: Array<String>|String, obj: Object): any

@@ -334,2 +349,3 @@ - Retrieve the value at `pathToSearch` in object `obj`

```javascript
R.path('a.b', {a: {b: 2}}) //=> 2
R.path(['a', 'b'], {a: {b: 2}}) //=> 2

@@ -336,0 +352,0 @@ R.path(['a', 'c'], {a: {b: 2}}) //=> undefined

2

index.js

@@ -1,1 +0,1 @@

module.exports=function(d){var e={};function __webpack_require__(g){if(e[g]){return e[g].exports;}var h=e[g]={i:g,l:!1,exports:{}};d[g].call(h.exports,h,h.exports,__webpack_require__);h.l=!0;return h.exports;}__webpack_require__.m=d;__webpack_require__.c=e;__webpack_require__.i=function(j){return j;};__webpack_require__.d=function(k,l,m){if(!__webpack_require__.o(k,l)){Object.defineProperty(k,l,{configurable:!1,enumerable:!0,get:m});}};__webpack_require__.n=function(n){var q=n&&n.__esModule?function getDefault(){return n['default'];}:function getModuleExports(){return n;};__webpack_require__.d(q,'a',q);return q;};__webpack_require__.o=function(r,s){return Object.prototype.hasOwnProperty.call(r,s);};__webpack_require__.p="";return __webpack_require__(__webpack_require__.s=53);}([function(t,u){function type(a){if(a===null){return"Null";}else if(Array.isArray(a)){return"Array";}else if(typeof a==="boolean"){return"Boolean";}else if(typeof a==="number"){return"Number";}else if(typeof a==="string"){return"String";}else if(a===void 0){return"Undefined";}else if(a instanceof RegExp){return"RegExp";}const v=a.toString();if(v.startsWith("async")){return"Async";}else if(v.includes("function")||v.includes("=>")){return"Function";}return"Object";}t.exports=type;},function(w,x){function baseSlice(y,z,A){let B=-1,C=y.length;A=A>C?C:A;if(A<0){A+=C;}C=z>A?0:A-z>>>0;z>>>=0;const D=Array(C);while(++B<C){D[B]=y[B+z];}return D;}w.exports=baseSlice;},function(E,F,G){const H=G(4);function contains(I,J){if(J===void 0){return K=>contains(I,K);}let L=-1,M=!1;while(++L<J.length&&!M){if(H(J[L],I)){M=!0;}}return M;}E.exports=contains;},function(N,O){function drop(P,a){if(a===void 0){return Q=>drop(P,Q);}return a.slice(P);}N.exports=drop;},function(R,S,T){const U=T(0);function equals(a,b){if(b===void 0){return V=>equals(a,V);}else if(a===b){return a!==0||1/a===1/b;}const W=U(a);if(W!==U(b)){return!1;}if(W==="Array"){const X=Array.from(a),Y=Array.from(b);return X.sort().toString()===Y.sort().toString();}if(W==="Object"){const Z=Object.keys(a);if(Z.length===Object.keys(b).length){if(Z.length===0){return!0;}let a1=!0;Z.map(b1=>{if(a1){const c1=U(a[b1]),d1=U(b[b1]);if(c1===d1){if(c1==="Object"){if(Object.keys(a[b1]).length===Object.keys(b[b1]).length){if(Object.keys(a[b1]).length!==0){if(!equals(a[b1],b[b1])){a1=!1;}}}else{a1=!1;}}else if(!equals(a[b1],b[b1])){a1=!1;}}else{a1=!1;}}});return a1;}}return!1;}R.exports=equals;},function(e1,f1){function map(fn,h1){if(h1===void 0){return i1=>map(fn,i1);}let j1=-1;const k1=h1.length,l1=Array(k1);while(++j1<k1){l1[j1]=fn(h1[j1]);}return l1;}e1.exports=map;},function(m1,n1){function merge(o1,p1){if(p1===void 0){return q1=>merge(o1,q1);}return Object.assign({},o1,p1);}m1.exports=merge;},function(r1,s1){function add(a,b){if(b===void 0){return c=>add(a,c);}return a+b;}r1.exports=add;},function(t1,u1){function adjust(fn,w1,x1){if(w1===void 0){return(y1,z1)=>adjust(fn,y1,z1);}else if(x1===void 0){return A1=>adjust(fn,w1,A1);}const B1=x1.concat();return B1.map((C1,D1)=>{if(D1===w1){return fn(x1[w1]);}return C1;});}t1.exports=adjust;},function(E1,F1){function any(fn,H1){if(H1===void 0){return I1=>any(fn,I1);}let J1=0;while(J1<H1.length){if(fn(H1[J1])){return!0;}J1++;}return!1;}E1.exports=any;},function(K1,L1){function append(M1,N1){if(N1===void 0){return O1=>append(M1,O1);}const P1=N1.concat();P1.push(M1);return P1;}K1.exports=append;},function(Q1,R1){function isFunction(S1){return typeof S1==="function";}function compose(){const T1=arguments;let U1=T1.length;while(U1--){if(!isFunction(T1[U1])){throw new TypeError();}}return function(){let V1=arguments,W1=T1.length;while(W1--){V1=[T1[W1].apply(this,V1)];}return V1[0];};}Q1.exports=compose;},function(X1,Y1){function curry(f,a=[]){return(...p)=>(o=>o.length===f.length?f(...o):curry(f,o))([...a,...p]);}X1.exports=curry;},function(Z1,a2,b2){const c2=b2(0);function defaultTo(d2,e2){if(arguments.length===1){return f2=>defaultTo(d2,f2);}return e2===void 0||!(c2(e2)===c2(d2))?d2:e2;}Z1.exports=defaultTo;},function(g2,h2){function dropLast(i2,a){if(a===void 0){return j2=>dropLast(i2,j2);}return a.slice(0,-i2);}g2.exports=dropLast;},function(k2,l2){function filter(fn,n2){if(n2===void 0){return o2=>filter(fn,o2);}let p2=-1,q2=0;const r2=n2.length,s2=[];while(++p2<r2){const t2=n2[p2];if(fn(t2)){s2[q2++]=t2;}}return s2;}k2.exports=filter;},function(u2,v2){function find(fn,x2){if(x2===void 0){return y2=>find(fn,y2);}return x2.find(fn);}u2.exports=find;},function(z2,A2){function findIndex(fn,C2){if(C2===void 0){return D2=>findIndex(fn,D2);}const E2=C2.length;let F2=-1;while(++F2<E2){if(fn(C2[F2])){return F2;}}return-1;}z2.exports=findIndex;},function(G2,H2){function flatten(I2,J2){J2=J2===void 0?[]:J2;for(let i=0;i<I2.length;i++){if(Array.isArray(I2[i])){flatten(I2[i],J2);}else{J2.push(I2[i]);}}return J2;}G2.exports=flatten;},function(K2,L2){function has(M2,N2){if(N2===void 0){return O2=>has(M2,O2);}return N2[M2]!==void 0;}K2.exports=has;},function(P2,Q2){function head(a){if(typeof a==="string"){return a[0]||"";}return a[0];}P2.exports=head;},function(R2,S2){function indexOf(T2,U2){if(U2===void 0){return V2=>indexOf(T2,V2);}let W2=-1;const X2=U2.length;while(++W2<X2){if(U2[W2]===T2){return W2;}}return-1;}R2.exports=indexOf;},function(Y2,Z2,a3){const b3=a3(1);function init(a){if(typeof a==="string"){return a.slice(0,-1);}return a.length?b3(a,0,-1):[];}Y2.exports=init;},function(c3,d3){function join(e3,f3){if(f3===void 0){return g3=>join(e3,g3);}return f3.join(e3);}c3.exports=join;},function(h3,i3){function last(a){if(typeof a==="string"){return a[a.length-1]||"";}return a[a.length-1];}h3.exports=last;},function(j3,k3){function length(l3){return l3.length;}j3.exports=length;},function(m3,n3){function match(o3,p3){if(p3===void 0){return q3=>match(o3,q3);}const r3=p3.match(o3);return r3===null?[]:r3;}m3.exports=match;},function(s3,t3){function omit(u3,v3){if(v3===void 0){return w3=>omit(u3,w3);}const x3={};for(key in v3){if(!u3.includes(key)){x3[key]=v3[key];}}return x3;}s3.exports=omit;},function(y3,z3,A3){const B3=A3(0),C3=A3(6);function curry(fn,E3={}){return F3=>{if(B3(fn)==="Async"){return new Promise((G3,H3)=>{fn(C3(F3,E3)).then(G3).catch(H3);});}return fn(C3(F3,E3));};}y3.exports=curry;},function(I3,J3){function path(K3,L3){if(L3===void 0){return M3=>path(K3,M3);}let N3=L3,O3=0;while(O3<K3.length){if(N3===null){return void 0;}N3=N3[K3[O3]];O3++;}return N3;}I3.exports=path;},function(P3,Q3){function pick(R3,S3){if(S3===void 0){return T3=>pick(R3,T3);}const U3={};let V3=0;while(V3<R3.length){if(R3[V3]in S3){U3[R3[V3]]=S3[R3[V3]];}V3++;}return U3;}P3.exports=pick;},function(W3,X3,Y3){const Z3=Y3(5);function pluck(a4,b4){if(b4===void 0){return c4=>pluck(a4,c4);}const d4=[];Z3(e4=>{if(!(e4[a4]===void 0)){d4.push(e4[a4]);}},b4);return d4;}W3.exports=pluck;},function(f4,g4){function prepend(h4,i4){if(i4===void 0){return j4=>prepend(h4,j4);}const k4=i4.concat();k4.unshift(h4);return k4;}f4.exports=prepend;},function(l4,m4){function prop(n4,o4){if(o4===void 0){return p4=>prop(n4,p4);}return o4[n4];}l4.exports=prop;},function(q4,r4){function propEq(s4,t4,u4){if(t4===void 0){return(v4,w4)=>propEq(s4,v4,w4);}else if(u4===void 0){return x4=>propEq(s4,t4,x4);}return u4[s4]===t4;}q4.exports=propEq;},function(y4,z4){function range(A4,B4){const C4=[];for(let i=A4;i<B4;i++){C4.push(i);}return C4;}y4.exports=range;},function(D4,E4){function repeat(a,F4){if(F4===void 0){return G4=>repeat(a,G4);}const H4=Array(F4);return H4.fill(a);}D4.exports=repeat;},function(I4,J4){function replace(K4,L4,M4){if(L4===void 0){return(N4,O4)=>replace(K4,N4,O4);}else if(M4===void 0){return P4=>replace(K4,L4,P4);}return M4.replace(K4,L4);}I4.exports=replace;},function(Q4,R4){function sort(fn,T4){if(T4===void 0){return U4=>sort(fn,U4);}const V4=T4.concat();return V4.sort(fn);}Q4.exports=sort;},function(W4,X4){function sortBy(fn,Z4){if(Z4===void 0){return a5=>sortBy(fn,a5);}const b5=Z4.concat();return b5.sort((a,b)=>{const c5=fn(a),d5=fn(b);return c5<d5?-1:c5>d5?1:0;});}W4.exports=sortBy;},function(e5,f5){function split(g5,h5){if(h5===void 0){return i5=>split(g5,i5);}return h5.split(g5);}e5.exports=split;},function(j5,k5){function splitEvery(l5,a){if(a===void 0){return m5=>splitEvery(l5,m5);}l5=l5>1?l5:1;const n5=[];let o5=0;while(o5<a.length){n5.push(a.slice(o5,o5+=l5));}return n5;}j5.exports=splitEvery;},function(p5,q5){function subtract(a,b){if(b===void 0){return r5=>subtract(a,r5);}return a-b;}p5.exports=subtract;},function(s5,t5,u5){const v5=u5(3);function tail(w5){return v5(1,w5);}s5.exports=tail;},function(x5,y5,z5){const A5=z5(1);function take(B5,a){if(a===void 0){return C5=>take(B5,C5);}else if(typeof a==="string"){return a.slice(0,B5);}return A5(a,0,B5);}x5.exports=take;},function(D5,E5,F5){const G5=F5(1);function takeLast(H5,a){if(a===void 0){return I5=>takeLast(H5,I5);}const J5=a.length;H5=H5>J5?J5:H5;if(typeof a==="string"){return a.slice(J5-H5);}H5=J5-H5;return G5(a,H5,J5);}D5.exports=takeLast;},function(K5,L5){function test(M5,N5){if(N5===void 0){return O5=>test(M5,O5);}return N5.search(M5)===-1?!1:!0;}K5.exports=test;},function(P5,Q5){function toLower(R5){return R5.toLowerCase();}P5.exports=toLower;},function(S5,T5){function toUpper(U5){return U5.toUpperCase();}S5.exports=toUpper;},function(V5,W5){function trim(X5){return X5.trim();}V5.exports=trim;},function(Y5,Z5,a6){const b6=a6(2);function uniq(c6){let d6=-1;const e6=[];while(++d6<c6.length){const f6=c6[d6];if(!b6(f6,e6)){e6.push(f6);}}return e6;}Y5.exports=uniq;},function(g6,h6){function update(i6,j6,k6){if(j6===void 0){return(l6,m6)=>update(i6,l6,m6);}else if(k6===void 0){return n6=>update(i6,j6,n6);}const o6=k6.concat();return o6.fill(j6,i6,i6+1);}g6.exports=update;},function(p6,q6){function values(r6){const s6=[];for(key in r6){s6.push(r6[key]);}return s6;}p6.exports=values;},function(t6,u6,v6){u6.add=v6(7);u6.any=v6(9);u6.adjust=v6(8);u6.append=v6(10);u6.compose=v6(11);u6.contains=v6(2);u6.curry=v6(12);u6.defaultTo=v6(13);u6.drop=v6(3);u6.dropLast=v6(14);u6.equals=v6(4);u6.filter=v6(15);u6.find=v6(16);u6.findIndex=v6(17);u6.flatten=v6(18);u6.has=v6(19);u6.head=v6(20);u6.indexOf=v6(21);u6.init=v6(22);u6.join=v6(23);u6.last=v6(24);u6.length=v6(25);u6.map=v6(5);u6.match=v6(26);u6.merge=v6(6);u6.omit=v6(27);u6.path=v6(29);u6.partialCurry=v6(28);u6.pick=v6(30);u6.pluck=v6(31);u6.prepend=v6(32);u6.prop=v6(33);u6.propEq=v6(34);u6.range=v6(35);u6.repeat=v6(36);u6.replace=v6(37);u6.sort=v6(38);u6.sortBy=v6(39);u6.split=v6(40);u6.splitEvery=v6(41);u6.subtract=v6(42);u6.tail=v6(43);u6.take=v6(44);u6.takeLast=v6(45);u6.test=v6(46);u6.toLower=v6(47);u6.toUpper=v6(48);u6.trim=v6(49);u6.type=v6(0);u6.uniq=v6(50);u6.update=v6(51);u6.values=v6(52);}]);
module.exports=function(d){var e={};function __webpack_require__(g){if(e[g]){return e[g].exports;}var h=e[g]={i:g,l:!1,exports:{}};d[g].call(h.exports,h,h.exports,__webpack_require__);h.l=!0;return h.exports;}__webpack_require__.m=d;__webpack_require__.c=e;__webpack_require__.i=function(j){return j;};__webpack_require__.d=function(k,l,m){if(!__webpack_require__.o(k,l)){Object.defineProperty(k,l,{configurable:!1,enumerable:!0,get:m});}};__webpack_require__.n=function(n){var q=n&&n.__esModule?function getDefault(){return n['default'];}:function getModuleExports(){return n;};__webpack_require__.d(q,'a',q);return q;};__webpack_require__.o=function(r,s){return Object.prototype.hasOwnProperty.call(r,s);};__webpack_require__.p="";return __webpack_require__(__webpack_require__.s=54);}([function(t,u){function type(a){if(a===null){return"Null";}else if(Array.isArray(a)){return"Array";}else if(typeof a==="boolean"){return"Boolean";}else if(typeof a==="number"){return"Number";}else if(typeof a==="string"){return"String";}else if(a===void 0){return"Undefined";}else if(a instanceof RegExp){return"RegExp";}const v=a.toString();if(v.startsWith("async")){return"Async";}else if(v.includes("function")||v.includes("=>")){return"Function";}return"Object";}t.exports=type;},function(w,x){function baseSlice(y,z,A){let B=-1,C=y.length;A=A>C?C:A;if(A<0){A+=C;}C=z>A?0:A-z>>>0;z>>>=0;const D=Array(C);while(++B<C){D[B]=y[B+z];}return D;}w.exports=baseSlice;},function(E,F,G){const H=G(4);function contains(I,J){if(J===void 0){return K=>contains(I,K);}let L=-1,M=!1;while(++L<J.length&&!M){if(H(J[L],I)){M=!0;}}return M;}E.exports=contains;},function(N,O){function drop(P,a){if(a===void 0){return Q=>drop(P,Q);}return a.slice(P);}N.exports=drop;},function(R,S,T){const U=T(0);function equals(a,b){if(b===void 0){return V=>equals(a,V);}else if(a===b){return a!==0||1/a===1/b;}const W=U(a);if(W!==U(b)){return!1;}if(W==="Array"){const X=Array.from(a),Y=Array.from(b);return X.sort().toString()===Y.sort().toString();}if(W==="Object"){const Z=Object.keys(a);if(Z.length===Object.keys(b).length){if(Z.length===0){return!0;}let a1=!0;Z.map(b1=>{if(a1){const c1=U(a[b1]),d1=U(b[b1]);if(c1===d1){if(c1==="Object"){if(Object.keys(a[b1]).length===Object.keys(b[b1]).length){if(Object.keys(a[b1]).length!==0){if(!equals(a[b1],b[b1])){a1=!1;}}}else{a1=!1;}}else if(!equals(a[b1],b[b1])){a1=!1;}}else{a1=!1;}}});return a1;}}return!1;}R.exports=equals;},function(e1,f1){function map(fn,h1){if(h1===void 0){return i1=>map(fn,i1);}let j1=-1;const k1=h1.length,l1=Array(k1);while(++j1<k1){l1[j1]=fn(h1[j1]);}return l1;}e1.exports=map;},function(m1,n1){function merge(o1,p1){if(p1===void 0){return q1=>merge(o1,q1);}return Object.assign({},o1,p1);}m1.exports=merge;},function(r1,s1){function add(a,b){if(b===void 0){return c=>add(a,c);}return a+b;}r1.exports=add;},function(t1,u1){function adjust(fn,w1,x1){if(w1===void 0){return(y1,z1)=>adjust(fn,y1,z1);}else if(x1===void 0){return A1=>adjust(fn,w1,A1);}const B1=x1.concat();return B1.map((C1,D1)=>{if(D1===w1){return fn(x1[w1]);}return C1;});}t1.exports=adjust;},function(E1,F1){function any(fn,H1){if(H1===void 0){return I1=>any(fn,I1);}let J1=0;while(J1<H1.length){if(fn(H1[J1])){return!0;}J1++;}return!1;}E1.exports=any;},function(K1,L1){function append(M1,N1){if(N1===void 0){return O1=>append(M1,O1);}const P1=N1.concat();P1.push(M1);return P1;}K1.exports=append;},function(Q1,R1){const compose=(...fns)=>S1=>{let T1=fns.slice();while(T1.length>0){S1=T1.pop()(S1);}return S1;};Q1.exports=compose;},function(U1,V1){function curry(f,a=[]){return(...p)=>(o=>o.length===f.length?f(...o):curry(f,o))([...a,...p]);}U1.exports=curry;},function(W1,X1,Y1){const Z1=Y1(0);function defaultTo(a2,b2){if(arguments.length===1){return c2=>defaultTo(a2,c2);}return b2===void 0||!(Z1(b2)===Z1(a2))?a2:b2;}W1.exports=defaultTo;},function(d2,e2){function dropLast(f2,a){if(a===void 0){return g2=>dropLast(f2,g2);}return a.slice(0,-f2);}d2.exports=dropLast;},function(h2,i2){function filter(fn,k2){if(k2===void 0){return l2=>filter(fn,l2);}let m2=-1,n2=0;const o2=k2.length,p2=[];while(++m2<o2){const q2=k2[m2];if(fn(q2)){p2[n2++]=q2;}}return p2;}h2.exports=filter;},function(r2,s2){function find(fn,u2){if(u2===void 0){return v2=>find(fn,v2);}return u2.find(fn);}r2.exports=find;},function(w2,x2){function findIndex(fn,z2){if(z2===void 0){return A2=>findIndex(fn,A2);}const B2=z2.length;let C2=-1;while(++C2<B2){if(fn(z2[C2])){return C2;}}return-1;}w2.exports=findIndex;},function(D2,E2){function flatten(F2,G2){G2=G2===void 0?[]:G2;for(let i=0;i<F2.length;i++){if(Array.isArray(F2[i])){flatten(F2[i],G2);}else{G2.push(F2[i]);}}return G2;}D2.exports=flatten;},function(H2,I2){function has(J2,K2){if(K2===void 0){return L2=>has(J2,L2);}return K2[J2]!==void 0;}H2.exports=has;},function(M2,N2){function head(a){if(typeof a==="string"){return a[0]||"";}return a[0];}M2.exports=head;},function(O2,P2){function indexOf(Q2,R2){if(R2===void 0){return S2=>indexOf(Q2,S2);}let T2=-1;const U2=R2.length;while(++T2<U2){if(R2[T2]===Q2){return T2;}}return-1;}O2.exports=indexOf;},function(V2,W2,X2){const Y2=X2(1);function init(a){if(typeof a==="string"){return a.slice(0,-1);}return a.length?Y2(a,0,-1):[];}V2.exports=init;},function(Z2,a3){function join(b3,c3){if(c3===void 0){return d3=>join(b3,d3);}return c3.join(b3);}Z2.exports=join;},function(e3,f3){function last(a){if(typeof a==="string"){return a[a.length-1]||"";}return a[a.length-1];}e3.exports=last;},function(g3,h3){function length(i3){return i3.length;}g3.exports=length;},function(j3,k3){function match(l3,m3){if(m3===void 0){return n3=>match(l3,n3);}const o3=m3.match(l3);return o3===null?[]:o3;}j3.exports=match;},function(p3,q3){function omit(r3,s3){if(s3===void 0){return t3=>omit(r3,t3);}const u3={};for(key in s3){if(!r3.includes(key)){u3[key]=s3[key];}}return u3;}p3.exports=omit;},function(v3,w3,x3){const y3=x3(0),z3=x3(6);function curry(fn,B3={}){return C3=>{if(y3(fn)==="Async"){return new Promise((D3,E3)=>{fn(z3(C3,B3)).then(D3).catch(E3);});}return fn(z3(C3,B3));};}v3.exports=curry;},function(F3,G3){function path(H3,I3){if(I3===void 0){return J3=>path(H3,J3);}let K3=I3,L3=0;if(typeof H3==="string"){H3=H3.split(".");}while(L3<H3.length){if(K3===null){return void 0;}K3=K3[H3[L3]];L3++;}return K3;}F3.exports=path;},function(M3,N3){function pick(O3,P3){if(P3===void 0){return Q3=>pick(O3,Q3);}const R3={};let S3=0;while(S3<O3.length){if(O3[S3]in P3){R3[O3[S3]]=P3[O3[S3]];}S3++;}return R3;}M3.exports=pick;},function(T3,U3,V3){const W3=V3(5);function pluck(X3,Y3){if(Y3===void 0){return Z3=>pluck(X3,Z3);}const a4=[];W3(b4=>{if(!(b4[X3]===void 0)){a4.push(b4[X3]);}},Y3);return a4;}T3.exports=pluck;},function(c4,d4){function prepend(e4,f4){if(f4===void 0){return g4=>prepend(e4,g4);}const h4=f4.concat();h4.unshift(e4);return h4;}c4.exports=prepend;},function(i4,j4){function prop(k4,l4){if(l4===void 0){return m4=>prop(k4,m4);}return l4[k4];}i4.exports=prop;},function(n4,o4){function propEq(p4,q4,r4){if(q4===void 0){return(s4,t4)=>propEq(p4,s4,t4);}else if(r4===void 0){return u4=>propEq(p4,q4,u4);}return r4[p4]===q4;}n4.exports=propEq;},function(v4,w4){function range(x4,y4){const z4=[];for(let i=x4;i<y4;i++){z4.push(i);}return z4;}v4.exports=range;},function(A4,B4){function reduce(fn,D4,E4){if(D4===void 0){return(F4,G4)=>reduce(fn,F4,G4);}else if(E4===void 0){return H4=>reduce(fn,D4,H4);}return E4.reduce(fn,D4);}A4.exports=reduce;},function(I4,J4){function repeat(a,K4){if(K4===void 0){return L4=>repeat(a,L4);}const M4=Array(K4);return M4.fill(a);}I4.exports=repeat;},function(N4,O4){function replace(P4,Q4,R4){if(Q4===void 0){return(S4,T4)=>replace(P4,S4,T4);}else if(R4===void 0){return U4=>replace(P4,Q4,U4);}return R4.replace(P4,Q4);}N4.exports=replace;},function(V4,W4){function sort(fn,Y4){if(Y4===void 0){return Z4=>sort(fn,Z4);}const a5=Y4.concat();return a5.sort(fn);}V4.exports=sort;},function(b5,c5){function sortBy(fn,e5){if(e5===void 0){return f5=>sortBy(fn,f5);}const g5=e5.concat();return g5.sort((a,b)=>{const h5=fn(a),i5=fn(b);return h5<i5?-1:h5>i5?1:0;});}b5.exports=sortBy;},function(j5,k5){function split(l5,m5){if(m5===void 0){return n5=>split(l5,n5);}return m5.split(l5);}j5.exports=split;},function(o5,p5){function splitEvery(q5,a){if(a===void 0){return r5=>splitEvery(q5,r5);}q5=q5>1?q5:1;const s5=[];let t5=0;while(t5<a.length){s5.push(a.slice(t5,t5+=q5));}return s5;}o5.exports=splitEvery;},function(u5,v5){function subtract(a,b){if(b===void 0){return w5=>subtract(a,w5);}return a-b;}u5.exports=subtract;},function(x5,y5,z5){const A5=z5(3);function tail(B5){return A5(1,B5);}x5.exports=tail;},function(C5,D5,E5){const F5=E5(1);function take(G5,a){if(a===void 0){return H5=>take(G5,H5);}else if(typeof a==="string"){return a.slice(0,G5);}return F5(a,0,G5);}C5.exports=take;},function(I5,J5,K5){const L5=K5(1);function takeLast(M5,a){if(a===void 0){return N5=>takeLast(M5,N5);}const O5=a.length;M5=M5>O5?O5:M5;if(typeof a==="string"){return a.slice(O5-M5);}M5=O5-M5;return L5(a,M5,O5);}I5.exports=takeLast;},function(P5,Q5){function test(R5,S5){if(S5===void 0){return T5=>test(R5,T5);}return S5.search(R5)===-1?!1:!0;}P5.exports=test;},function(U5,V5){function toLower(W5){return W5.toLowerCase();}U5.exports=toLower;},function(X5,Y5){function toUpper(Z5){return Z5.toUpperCase();}X5.exports=toUpper;},function(a6,b6){function trim(c6){return c6.trim();}a6.exports=trim;},function(d6,e6,f6){const g6=f6(2);function uniq(h6){let i6=-1;const j6=[];while(++i6<h6.length){const k6=h6[i6];if(!g6(k6,j6)){j6.push(k6);}}return j6;}d6.exports=uniq;},function(l6,m6){function update(n6,o6,p6){if(o6===void 0){return(q6,r6)=>update(n6,q6,r6);}else if(p6===void 0){return s6=>update(n6,o6,s6);}const t6=p6.concat();return t6.fill(o6,n6,n6+1);}l6.exports=update;},function(u6,v6){function values(w6){const x6=[];for(key in w6){x6.push(w6[key]);}return x6;}u6.exports=values;},function(y6,z6,A6){z6.add=A6(7);z6.any=A6(9);z6.adjust=A6(8);z6.append=A6(10);z6.compose=A6(11);z6.contains=A6(2);z6.curry=A6(12);z6.defaultTo=A6(13);z6.drop=A6(3);z6.dropLast=A6(14);z6.equals=A6(4);z6.filter=A6(15);z6.find=A6(16);z6.findIndex=A6(17);z6.flatten=A6(18);z6.has=A6(19);z6.head=A6(20);z6.indexOf=A6(21);z6.init=A6(22);z6.join=A6(23);z6.last=A6(24);z6.length=A6(25);z6.map=A6(5);z6.match=A6(26);z6.merge=A6(6);z6.omit=A6(27);z6.path=A6(29);z6.partialCurry=A6(28);z6.pick=A6(30);z6.pluck=A6(31);z6.prepend=A6(32);z6.prop=A6(33);z6.propEq=A6(34);z6.range=A6(35);z6.repeat=A6(37);z6.replace=A6(38);z6.sort=A6(39);z6.sortBy=A6(40);z6.split=A6(41);z6.splitEvery=A6(42);z6.subtract=A6(43);z6.tail=A6(44);z6.take=A6(45);z6.takeLast=A6(46);z6.test=A6(47);z6.toLower=A6(48);z6.toUpper=A6(49);z6.trim=A6(50);z6.type=A6(0);z6.uniq=A6(51);z6.update=A6(52);z6.values=A6(53);z6.reduce=A6(36);}]);

@@ -1,28 +0,13 @@

function isFunction(value){
// Taken from https://github.com/getify/Functional-Light-JS/blob/master/ch4.md
const compose = (...fns) =>
result => {
let list = fns.slice()
return typeof value === "function"
}
function compose () {
const funcs = arguments
let length = funcs.length
while (length--) {
if (!isFunction(funcs[ length ])) {
throw new TypeError
while (list.length > 0) {
result = list.pop()(result)
}
}
return function () {
let args = arguments
let len = funcs.length
while (len--) {
args = [ funcs[ len ].apply(this, args) ]
}
return args[ 0 ]
return result
}
}
module.exports = compose

@@ -8,2 +8,5 @@ function path(pathArr, obj) {

let counter = 0
if(typeof pathArr === "string"){
pathArr = pathArr.split(".")
}
while (counter < pathArr.length) {

@@ -10,0 +13,0 @@ if (holder === null) {

{
"name": "rambda",
"version": "0.7.0",
"version": "0.7.1",
"description": "Lightweight alternative to Ramda",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -53,1 +53,2 @@ exports.add = require("./modules/add")

exports.values = require("./modules/values")
exports.reduce = require("./modules/reduce")

@@ -34,3 +34,3 @@ [![Build Status](https://img.shields.io/travis/selfrefactor/rambda.svg)](https://travis-ci.org/selfrefactor/rambda)

```
https://cdnjs.cloudflare.com/ajax/libs/rambda/0.7.0/webVersion.js
https://cdnjs.cloudflare.com/ajax/libs/rambda/0.7.1/webVersion.js
```

@@ -52,2 +52,4 @@

- Rambda's **path** accepts both string and array as object path.
- **Rambda** is tested for compatability with **Ramda.flip**, as this method could be useful in some cases.

@@ -96,2 +98,15 @@

#### compose
> compose(fn1: Function, ... , fnN: Function): any
Performs right-to-left function composition
```
const result = R.compose(
R.map(a => a*2)
R.filter(val => val>2),
)([1, 2, 3, 4])
console.log(result) // => [6, 8]
```
#### contains

@@ -329,3 +344,3 @@

> path(pathToSearch: Array<String>, obj: Object): any
> path(pathToSearch: Array<String>|String, obj: Object): any

@@ -335,2 +350,3 @@ - Retrieve the value at `pathToSearch` in object `obj`

```javascript
R.path('a.b', {a: {b: 2}}) //=> 2
R.path(['a', 'b'], {a: {b: 2}}) //=> 2

@@ -635,2 +651,3 @@ R.path(['a', 'c'], {a: {b: 2}}) //=> undefined

- 0.7.1 Close [issue #7](https://github.com/selfrefactor/rambda/issues/5) - add `R.reduce` to the API
- 0.7.0 Close [issue #5](https://github.com/selfrefactor/rambda/issues/5) - change name of `curry` to `partialCurry`; add new method `curry`, which works just like Ramda's `curry`

@@ -637,0 +654,0 @@ - 0.6.2 Add separate documentation site via `docsify`

@@ -1,1 +0,1 @@

(function webpackUniversalModuleDefinition(d,e){if(typeof exports==='object'&&typeof module==='object')module.exports=e();else if(typeof define==='function'&&define.amd)define([],e);else{var a=e();for(var i in a)(typeof exports==='object'?exports:d)[i]=a[i];}})(this,function(){return function(g){var h={};function __webpack_require__(j){if(h[j]){return h[j].exports;}var k=h[j]={i:j,l:!1,exports:{}};g[j].call(k.exports,k,k.exports,__webpack_require__);k.l=!0;return k.exports;}__webpack_require__.m=g;__webpack_require__.c=h;__webpack_require__.i=function(l){return l;};__webpack_require__.d=function(m,n,q){if(!__webpack_require__.o(m,n)){Object.defineProperty(m,n,{configurable:!1,enumerable:!0,get:q});}};__webpack_require__.n=function(r){var s=r&&r.__esModule?function getDefault(){return r['default'];}:function getModuleExports(){return r;};__webpack_require__.d(s,'a',s);return s;};__webpack_require__.o=function(t,u){return Object.prototype.hasOwnProperty.call(t,u);};__webpack_require__.p="";return __webpack_require__(__webpack_require__.s=8);}([function(v,w){function type(a){if(a===null){return"Null";}else if(Array.isArray(a)){return"Array";}else if(typeof a==="boolean"){return"Boolean";}else if(typeof a==="number"){return"Number";}else if(typeof a==="string"){return"String";}else if(a===void 0){return"Undefined";}else if(a instanceof RegExp){return"RegExp";}const x=a.toString();if(x.startsWith("async")){return"Async";}else if(x.includes("function")||x.includes("=>")){return"Function";}return"Object";}v.exports=type;},function(y,z){function baseSlice(A,B,C){let D=-1,E=A.length;C=C>E?E:C;if(C<0){C+=E;}E=B>C?0:C-B>>>0;B>>>=0;const F=Array(E);while(++D<E){F[D]=A[D+B];}return F;}y.exports=baseSlice;},function(G,H,I){const J=I(4);function contains(K,L){if(L===void 0){return M=>contains(K,M);}let N=-1,O=!1;while(++N<L.length&&!O){if(J(L[N],K)){O=!0;}}return O;}G.exports=contains;},function(P,Q){function drop(R,a){if(a===void 0){return S=>drop(R,S);}return a.slice(R);}P.exports=drop;},function(T,U,V){const W=V(0);function equals(a,b){if(b===void 0){return X=>equals(a,X);}else if(a===b){return a!==0||1/a===1/b;}const Y=W(a);if(Y!==W(b)){return!1;}if(Y==="Array"){const Z=Array.from(a),a1=Array.from(b);return Z.sort().toString()===a1.sort().toString();}if(Y==="Object"){const b1=Object.keys(a);if(b1.length===Object.keys(b).length){if(b1.length===0){return!0;}let c1=!0;b1.map(d1=>{if(c1){const e1=W(a[d1]),f1=W(b[d1]);if(e1===f1){if(e1==="Object"){if(Object.keys(a[d1]).length===Object.keys(b[d1]).length){if(Object.keys(a[d1]).length!==0){if(!equals(a[d1],b[d1])){c1=!1;}}}else{c1=!1;}}else if(!equals(a[d1],b[d1])){c1=!1;}}else{c1=!1;}}});return c1;}}return!1;}T.exports=equals;},function(g1,h1){function map(fn,j1){if(j1===void 0){return k1=>map(fn,k1);}let l1=-1;const m1=j1.length,n1=Array(m1);while(++l1<m1){n1[l1]=fn(j1[l1]);}return n1;}g1.exports=map;},function(o1,p1){function merge(q1,r1){if(r1===void 0){return s1=>merge(q1,s1);}return Object.assign({},q1,r1);}o1.exports=merge;},function(t1,u1,v1){u1.add=v1(9);u1.any=v1(11);u1.adjust=v1(10);u1.append=v1(12);u1.compose=v1(13);u1.contains=v1(2);u1.curry=v1(14);u1.defaultTo=v1(15);u1.drop=v1(3);u1.dropLast=v1(16);u1.equals=v1(4);u1.filter=v1(17);u1.find=v1(18);u1.findIndex=v1(19);u1.flatten=v1(20);u1.has=v1(21);u1.head=v1(22);u1.indexOf=v1(23);u1.init=v1(24);u1.join=v1(25);u1.last=v1(26);u1.length=v1(27);u1.map=v1(5);u1.match=v1(28);u1.merge=v1(6);u1.omit=v1(29);u1.path=v1(31);u1.partialCurry=v1(30);u1.pick=v1(32);u1.pluck=v1(33);u1.prepend=v1(34);u1.prop=v1(35);u1.propEq=v1(36);u1.range=v1(37);u1.repeat=v1(38);u1.replace=v1(39);u1.sort=v1(40);u1.sortBy=v1(41);u1.split=v1(42);u1.splitEvery=v1(43);u1.subtract=v1(44);u1.tail=v1(45);u1.take=v1(46);u1.takeLast=v1(47);u1.test=v1(48);u1.toLower=v1(49);u1.toUpper=v1(50);u1.trim=v1(51);u1.type=v1(0);u1.uniq=v1(52);u1.update=v1(53);u1.values=v1(54);},function(w1,x1,y1){const z1=y1(7);w1.exports.R=z1;},function(A1,B1){function add(a,b){if(b===void 0){return c=>add(a,c);}return a+b;}A1.exports=add;},function(C1,D1){function adjust(fn,F1,G1){if(F1===void 0){return(H1,I1)=>adjust(fn,H1,I1);}else if(G1===void 0){return J1=>adjust(fn,F1,J1);}const K1=G1.concat();return K1.map((L1,M1)=>{if(M1===F1){return fn(G1[F1]);}return L1;});}C1.exports=adjust;},function(N1,O1){function any(fn,Q1){if(Q1===void 0){return R1=>any(fn,R1);}let S1=0;while(S1<Q1.length){if(fn(Q1[S1])){return!0;}S1++;}return!1;}N1.exports=any;},function(T1,U1){function append(V1,W1){if(W1===void 0){return X1=>append(V1,X1);}const Y1=W1.concat();Y1.push(V1);return Y1;}T1.exports=append;},function(Z1,a2){function isFunction(b2){return typeof b2==="function";}function compose(){const c2=arguments;let d2=c2.length;while(d2--){if(!isFunction(c2[d2])){throw new TypeError();}}return function(){let e2=arguments,f2=c2.length;while(f2--){e2=[c2[f2].apply(this,e2)];}return e2[0];};}Z1.exports=compose;},function(g2,h2){function curry(f,a=[]){return(...p)=>(o=>o.length===f.length?f(...o):curry(f,o))([...a,...p]);}g2.exports=curry;},function(i2,j2,k2){const l2=k2(0);function defaultTo(m2,n2){if(arguments.length===1){return o2=>defaultTo(m2,o2);}return n2===void 0||!(l2(n2)===l2(m2))?m2:n2;}i2.exports=defaultTo;},function(p2,q2){function dropLast(r2,a){if(a===void 0){return s2=>dropLast(r2,s2);}return a.slice(0,-r2);}p2.exports=dropLast;},function(t2,u2){function filter(fn,w2){if(w2===void 0){return x2=>filter(fn,x2);}let y2=-1,z2=0;const A2=w2.length,B2=[];while(++y2<A2){const C2=w2[y2];if(fn(C2)){B2[z2++]=C2;}}return B2;}t2.exports=filter;},function(D2,E2){function find(fn,G2){if(G2===void 0){return H2=>find(fn,H2);}return G2.find(fn);}D2.exports=find;},function(I2,J2){function findIndex(fn,L2){if(L2===void 0){return M2=>findIndex(fn,M2);}const N2=L2.length;let O2=-1;while(++O2<N2){if(fn(L2[O2])){return O2;}}return-1;}I2.exports=findIndex;},function(P2,Q2){function flatten(R2,S2){S2=S2===void 0?[]:S2;for(let i=0;i<R2.length;i++){if(Array.isArray(R2[i])){flatten(R2[i],S2);}else{S2.push(R2[i]);}}return S2;}P2.exports=flatten;},function(T2,U2){function has(V2,W2){if(W2===void 0){return X2=>has(V2,X2);}return W2[V2]!==void 0;}T2.exports=has;},function(Y2,Z2){function head(a){if(typeof a==="string"){return a[0]||"";}return a[0];}Y2.exports=head;},function(a3,b3){function indexOf(c3,d3){if(d3===void 0){return e3=>indexOf(c3,e3);}let f3=-1;const g3=d3.length;while(++f3<g3){if(d3[f3]===c3){return f3;}}return-1;}a3.exports=indexOf;},function(h3,i3,j3){const k3=j3(1);function init(a){if(typeof a==="string"){return a.slice(0,-1);}return a.length?k3(a,0,-1):[];}h3.exports=init;},function(l3,m3){function join(n3,o3){if(o3===void 0){return p3=>join(n3,p3);}return o3.join(n3);}l3.exports=join;},function(q3,r3){function last(a){if(typeof a==="string"){return a[a.length-1]||"";}return a[a.length-1];}q3.exports=last;},function(s3,t3){function length(u3){return u3.length;}s3.exports=length;},function(v3,w3){function match(x3,y3){if(y3===void 0){return z3=>match(x3,z3);}const A3=y3.match(x3);return A3===null?[]:A3;}v3.exports=match;},function(B3,C3){function omit(D3,E3){if(E3===void 0){return F3=>omit(D3,F3);}const G3={};for(key in E3){if(!D3.includes(key)){G3[key]=E3[key];}}return G3;}B3.exports=omit;},function(H3,I3,J3){const K3=J3(0),L3=J3(6);function curry(fn,N3={}){return O3=>{if(K3(fn)==="Async"){return new Promise((P3,Q3)=>{fn(L3(O3,N3)).then(P3).catch(Q3);});}return fn(L3(O3,N3));};}H3.exports=curry;},function(R3,S3){function path(T3,U3){if(U3===void 0){return V3=>path(T3,V3);}let W3=U3,X3=0;while(X3<T3.length){if(W3===null){return void 0;}W3=W3[T3[X3]];X3++;}return W3;}R3.exports=path;},function(Y3,Z3){function pick(a4,b4){if(b4===void 0){return c4=>pick(a4,c4);}const d4={};let e4=0;while(e4<a4.length){if(a4[e4]in b4){d4[a4[e4]]=b4[a4[e4]];}e4++;}return d4;}Y3.exports=pick;},function(f4,g4,h4){const i4=h4(5);function pluck(j4,k4){if(k4===void 0){return l4=>pluck(j4,l4);}const m4=[];i4(n4=>{if(!(n4[j4]===void 0)){m4.push(n4[j4]);}},k4);return m4;}f4.exports=pluck;},function(o4,p4){function prepend(q4,r4){if(r4===void 0){return s4=>prepend(q4,s4);}const t4=r4.concat();t4.unshift(q4);return t4;}o4.exports=prepend;},function(u4,v4){function prop(w4,x4){if(x4===void 0){return y4=>prop(w4,y4);}return x4[w4];}u4.exports=prop;},function(z4,A4){function propEq(B4,C4,D4){if(C4===void 0){return(E4,F4)=>propEq(B4,E4,F4);}else if(D4===void 0){return G4=>propEq(B4,C4,G4);}return D4[B4]===C4;}z4.exports=propEq;},function(H4,I4){function range(J4,K4){const L4=[];for(let i=J4;i<K4;i++){L4.push(i);}return L4;}H4.exports=range;},function(M4,N4){function repeat(a,O4){if(O4===void 0){return P4=>repeat(a,P4);}const Q4=Array(O4);return Q4.fill(a);}M4.exports=repeat;},function(R4,S4){function replace(T4,U4,V4){if(U4===void 0){return(W4,X4)=>replace(T4,W4,X4);}else if(V4===void 0){return Y4=>replace(T4,U4,Y4);}return V4.replace(T4,U4);}R4.exports=replace;},function(Z4,a5){function sort(fn,c5){if(c5===void 0){return d5=>sort(fn,d5);}const e5=c5.concat();return e5.sort(fn);}Z4.exports=sort;},function(f5,g5){function sortBy(fn,i5){if(i5===void 0){return j5=>sortBy(fn,j5);}const k5=i5.concat();return k5.sort((a,b)=>{const l5=fn(a),m5=fn(b);return l5<m5?-1:l5>m5?1:0;});}f5.exports=sortBy;},function(n5,o5){function split(p5,q5){if(q5===void 0){return r5=>split(p5,r5);}return q5.split(p5);}n5.exports=split;},function(s5,t5){function splitEvery(u5,a){if(a===void 0){return v5=>splitEvery(u5,v5);}u5=u5>1?u5:1;const w5=[];let x5=0;while(x5<a.length){w5.push(a.slice(x5,x5+=u5));}return w5;}s5.exports=splitEvery;},function(y5,z5){function subtract(a,b){if(b===void 0){return A5=>subtract(a,A5);}return a-b;}y5.exports=subtract;},function(B5,C5,D5){const E5=D5(3);function tail(F5){return E5(1,F5);}B5.exports=tail;},function(G5,H5,I5){const J5=I5(1);function take(K5,a){if(a===void 0){return L5=>take(K5,L5);}else if(typeof a==="string"){return a.slice(0,K5);}return J5(a,0,K5);}G5.exports=take;},function(M5,N5,O5){const P5=O5(1);function takeLast(Q5,a){if(a===void 0){return R5=>takeLast(Q5,R5);}const S5=a.length;Q5=Q5>S5?S5:Q5;if(typeof a==="string"){return a.slice(S5-Q5);}Q5=S5-Q5;return P5(a,Q5,S5);}M5.exports=takeLast;},function(T5,U5){function test(V5,W5){if(W5===void 0){return X5=>test(V5,X5);}return W5.search(V5)===-1?!1:!0;}T5.exports=test;},function(Y5,Z5){function toLower(a6){return a6.toLowerCase();}Y5.exports=toLower;},function(b6,c6){function toUpper(d6){return d6.toUpperCase();}b6.exports=toUpper;},function(e6,f6){function trim(g6){return g6.trim();}e6.exports=trim;},function(h6,i6,j6){const k6=j6(2);function uniq(l6){let m6=-1;const n6=[];while(++m6<l6.length){const o6=l6[m6];if(!k6(o6,n6)){n6.push(o6);}}return n6;}h6.exports=uniq;},function(p6,q6){function update(r6,s6,t6){if(s6===void 0){return(u6,v6)=>update(r6,u6,v6);}else if(t6===void 0){return w6=>update(r6,s6,w6);}const x6=t6.concat();return x6.fill(s6,r6,r6+1);}p6.exports=update;},function(y6,z6){function values(A6){const B6=[];for(key in A6){B6.push(A6[key]);}return B6;}y6.exports=values;}]);});
(function webpackUniversalModuleDefinition(d,e){if(typeof exports==='object'&&typeof module==='object')module.exports=e();else if(typeof define==='function'&&define.amd)define([],e);else{var a=e();for(var i in a)(typeof exports==='object'?exports:d)[i]=a[i];}})(this,function(){return function(g){var h={};function __webpack_require__(j){if(h[j]){return h[j].exports;}var k=h[j]={i:j,l:!1,exports:{}};g[j].call(k.exports,k,k.exports,__webpack_require__);k.l=!0;return k.exports;}__webpack_require__.m=g;__webpack_require__.c=h;__webpack_require__.i=function(l){return l;};__webpack_require__.d=function(m,n,q){if(!__webpack_require__.o(m,n)){Object.defineProperty(m,n,{configurable:!1,enumerable:!0,get:q});}};__webpack_require__.n=function(r){var s=r&&r.__esModule?function getDefault(){return r['default'];}:function getModuleExports(){return r;};__webpack_require__.d(s,'a',s);return s;};__webpack_require__.o=function(t,u){return Object.prototype.hasOwnProperty.call(t,u);};__webpack_require__.p="";return __webpack_require__(__webpack_require__.s=8);}([function(v,w){function type(a){if(a===null){return"Null";}else if(Array.isArray(a)){return"Array";}else if(typeof a==="boolean"){return"Boolean";}else if(typeof a==="number"){return"Number";}else if(typeof a==="string"){return"String";}else if(a===void 0){return"Undefined";}else if(a instanceof RegExp){return"RegExp";}const x=a.toString();if(x.startsWith("async")){return"Async";}else if(x.includes("function")||x.includes("=>")){return"Function";}return"Object";}v.exports=type;},function(y,z){function baseSlice(A,B,C){let D=-1,E=A.length;C=C>E?E:C;if(C<0){C+=E;}E=B>C?0:C-B>>>0;B>>>=0;const F=Array(E);while(++D<E){F[D]=A[D+B];}return F;}y.exports=baseSlice;},function(G,H,I){const J=I(4);function contains(K,L){if(L===void 0){return M=>contains(K,M);}let N=-1,O=!1;while(++N<L.length&&!O){if(J(L[N],K)){O=!0;}}return O;}G.exports=contains;},function(P,Q){function drop(R,a){if(a===void 0){return S=>drop(R,S);}return a.slice(R);}P.exports=drop;},function(T,U,V){const W=V(0);function equals(a,b){if(b===void 0){return X=>equals(a,X);}else if(a===b){return a!==0||1/a===1/b;}const Y=W(a);if(Y!==W(b)){return!1;}if(Y==="Array"){const Z=Array.from(a),a1=Array.from(b);return Z.sort().toString()===a1.sort().toString();}if(Y==="Object"){const b1=Object.keys(a);if(b1.length===Object.keys(b).length){if(b1.length===0){return!0;}let c1=!0;b1.map(d1=>{if(c1){const e1=W(a[d1]),f1=W(b[d1]);if(e1===f1){if(e1==="Object"){if(Object.keys(a[d1]).length===Object.keys(b[d1]).length){if(Object.keys(a[d1]).length!==0){if(!equals(a[d1],b[d1])){c1=!1;}}}else{c1=!1;}}else if(!equals(a[d1],b[d1])){c1=!1;}}else{c1=!1;}}});return c1;}}return!1;}T.exports=equals;},function(g1,h1){function map(fn,j1){if(j1===void 0){return k1=>map(fn,k1);}let l1=-1;const m1=j1.length,n1=Array(m1);while(++l1<m1){n1[l1]=fn(j1[l1]);}return n1;}g1.exports=map;},function(o1,p1){function merge(q1,r1){if(r1===void 0){return s1=>merge(q1,s1);}return Object.assign({},q1,r1);}o1.exports=merge;},function(t1,u1,v1){u1.add=v1(9);u1.any=v1(11);u1.adjust=v1(10);u1.append=v1(12);u1.compose=v1(13);u1.contains=v1(2);u1.curry=v1(14);u1.defaultTo=v1(15);u1.drop=v1(3);u1.dropLast=v1(16);u1.equals=v1(4);u1.filter=v1(17);u1.find=v1(18);u1.findIndex=v1(19);u1.flatten=v1(20);u1.has=v1(21);u1.head=v1(22);u1.indexOf=v1(23);u1.init=v1(24);u1.join=v1(25);u1.last=v1(26);u1.length=v1(27);u1.map=v1(5);u1.match=v1(28);u1.merge=v1(6);u1.omit=v1(29);u1.path=v1(31);u1.partialCurry=v1(30);u1.pick=v1(32);u1.pluck=v1(33);u1.prepend=v1(34);u1.prop=v1(35);u1.propEq=v1(36);u1.range=v1(37);u1.repeat=v1(39);u1.replace=v1(40);u1.sort=v1(41);u1.sortBy=v1(42);u1.split=v1(43);u1.splitEvery=v1(44);u1.subtract=v1(45);u1.tail=v1(46);u1.take=v1(47);u1.takeLast=v1(48);u1.test=v1(49);u1.toLower=v1(50);u1.toUpper=v1(51);u1.trim=v1(52);u1.type=v1(0);u1.uniq=v1(53);u1.update=v1(54);u1.values=v1(55);u1.reduce=v1(38);},function(w1,x1,y1){const z1=y1(7);w1.exports.R=z1;},function(A1,B1){function add(a,b){if(b===void 0){return c=>add(a,c);}return a+b;}A1.exports=add;},function(C1,D1){function adjust(fn,F1,G1){if(F1===void 0){return(H1,I1)=>adjust(fn,H1,I1);}else if(G1===void 0){return J1=>adjust(fn,F1,J1);}const K1=G1.concat();return K1.map((L1,M1)=>{if(M1===F1){return fn(G1[F1]);}return L1;});}C1.exports=adjust;},function(N1,O1){function any(fn,Q1){if(Q1===void 0){return R1=>any(fn,R1);}let S1=0;while(S1<Q1.length){if(fn(Q1[S1])){return!0;}S1++;}return!1;}N1.exports=any;},function(T1,U1){function append(V1,W1){if(W1===void 0){return X1=>append(V1,X1);}const Y1=W1.concat();Y1.push(V1);return Y1;}T1.exports=append;},function(Z1,a2){const compose=(...fns)=>b2=>{let c2=fns.slice();while(c2.length>0){b2=c2.pop()(b2);}return b2;};Z1.exports=compose;},function(d2,e2){function curry(f,a=[]){return(...p)=>(o=>o.length===f.length?f(...o):curry(f,o))([...a,...p]);}d2.exports=curry;},function(f2,g2,h2){const i2=h2(0);function defaultTo(j2,k2){if(arguments.length===1){return l2=>defaultTo(j2,l2);}return k2===void 0||!(i2(k2)===i2(j2))?j2:k2;}f2.exports=defaultTo;},function(m2,n2){function dropLast(o2,a){if(a===void 0){return p2=>dropLast(o2,p2);}return a.slice(0,-o2);}m2.exports=dropLast;},function(q2,r2){function filter(fn,t2){if(t2===void 0){return u2=>filter(fn,u2);}let v2=-1,w2=0;const x2=t2.length,y2=[];while(++v2<x2){const z2=t2[v2];if(fn(z2)){y2[w2++]=z2;}}return y2;}q2.exports=filter;},function(A2,B2){function find(fn,D2){if(D2===void 0){return E2=>find(fn,E2);}return D2.find(fn);}A2.exports=find;},function(F2,G2){function findIndex(fn,I2){if(I2===void 0){return J2=>findIndex(fn,J2);}const K2=I2.length;let L2=-1;while(++L2<K2){if(fn(I2[L2])){return L2;}}return-1;}F2.exports=findIndex;},function(M2,N2){function flatten(O2,P2){P2=P2===void 0?[]:P2;for(let i=0;i<O2.length;i++){if(Array.isArray(O2[i])){flatten(O2[i],P2);}else{P2.push(O2[i]);}}return P2;}M2.exports=flatten;},function(Q2,R2){function has(S2,T2){if(T2===void 0){return U2=>has(S2,U2);}return T2[S2]!==void 0;}Q2.exports=has;},function(V2,W2){function head(a){if(typeof a==="string"){return a[0]||"";}return a[0];}V2.exports=head;},function(X2,Y2){function indexOf(Z2,a3){if(a3===void 0){return b3=>indexOf(Z2,b3);}let c3=-1;const d3=a3.length;while(++c3<d3){if(a3[c3]===Z2){return c3;}}return-1;}X2.exports=indexOf;},function(e3,f3,g3){const h3=g3(1);function init(a){if(typeof a==="string"){return a.slice(0,-1);}return a.length?h3(a,0,-1):[];}e3.exports=init;},function(i3,j3){function join(k3,l3){if(l3===void 0){return m3=>join(k3,m3);}return l3.join(k3);}i3.exports=join;},function(n3,o3){function last(a){if(typeof a==="string"){return a[a.length-1]||"";}return a[a.length-1];}n3.exports=last;},function(p3,q3){function length(r3){return r3.length;}p3.exports=length;},function(s3,t3){function match(u3,v3){if(v3===void 0){return w3=>match(u3,w3);}const x3=v3.match(u3);return x3===null?[]:x3;}s3.exports=match;},function(y3,z3){function omit(A3,B3){if(B3===void 0){return C3=>omit(A3,C3);}const D3={};for(key in B3){if(!A3.includes(key)){D3[key]=B3[key];}}return D3;}y3.exports=omit;},function(E3,F3,G3){const H3=G3(0),I3=G3(6);function curry(fn,K3={}){return L3=>{if(H3(fn)==="Async"){return new Promise((M3,N3)=>{fn(I3(L3,K3)).then(M3).catch(N3);});}return fn(I3(L3,K3));};}E3.exports=curry;},function(O3,P3){function path(Q3,R3){if(R3===void 0){return S3=>path(Q3,S3);}let T3=R3,U3=0;if(typeof Q3==="string"){Q3=Q3.split(".");}while(U3<Q3.length){if(T3===null){return void 0;}T3=T3[Q3[U3]];U3++;}return T3;}O3.exports=path;},function(V3,W3){function pick(X3,Y3){if(Y3===void 0){return Z3=>pick(X3,Z3);}const a4={};let b4=0;while(b4<X3.length){if(X3[b4]in Y3){a4[X3[b4]]=Y3[X3[b4]];}b4++;}return a4;}V3.exports=pick;},function(c4,d4,e4){const f4=e4(5);function pluck(g4,h4){if(h4===void 0){return i4=>pluck(g4,i4);}const j4=[];f4(k4=>{if(!(k4[g4]===void 0)){j4.push(k4[g4]);}},h4);return j4;}c4.exports=pluck;},function(l4,m4){function prepend(n4,o4){if(o4===void 0){return p4=>prepend(n4,p4);}const q4=o4.concat();q4.unshift(n4);return q4;}l4.exports=prepend;},function(r4,s4){function prop(t4,u4){if(u4===void 0){return v4=>prop(t4,v4);}return u4[t4];}r4.exports=prop;},function(w4,x4){function propEq(y4,z4,A4){if(z4===void 0){return(B4,C4)=>propEq(y4,B4,C4);}else if(A4===void 0){return D4=>propEq(y4,z4,D4);}return A4[y4]===z4;}w4.exports=propEq;},function(E4,F4){function range(G4,H4){const I4=[];for(let i=G4;i<H4;i++){I4.push(i);}return I4;}E4.exports=range;},function(J4,K4){function reduce(fn,M4,N4){if(M4===void 0){return(O4,P4)=>reduce(fn,O4,P4);}else if(N4===void 0){return Q4=>reduce(fn,M4,Q4);}return N4.reduce(fn,M4);}J4.exports=reduce;},function(R4,S4){function repeat(a,T4){if(T4===void 0){return U4=>repeat(a,U4);}const V4=Array(T4);return V4.fill(a);}R4.exports=repeat;},function(W4,X4){function replace(Y4,Z4,a5){if(Z4===void 0){return(b5,c5)=>replace(Y4,b5,c5);}else if(a5===void 0){return d5=>replace(Y4,Z4,d5);}return a5.replace(Y4,Z4);}W4.exports=replace;},function(e5,f5){function sort(fn,h5){if(h5===void 0){return i5=>sort(fn,i5);}const j5=h5.concat();return j5.sort(fn);}e5.exports=sort;},function(k5,l5){function sortBy(fn,n5){if(n5===void 0){return o5=>sortBy(fn,o5);}const p5=n5.concat();return p5.sort((a,b)=>{const q5=fn(a),r5=fn(b);return q5<r5?-1:q5>r5?1:0;});}k5.exports=sortBy;},function(s5,t5){function split(u5,v5){if(v5===void 0){return w5=>split(u5,w5);}return v5.split(u5);}s5.exports=split;},function(x5,y5){function splitEvery(z5,a){if(a===void 0){return A5=>splitEvery(z5,A5);}z5=z5>1?z5:1;const B5=[];let C5=0;while(C5<a.length){B5.push(a.slice(C5,C5+=z5));}return B5;}x5.exports=splitEvery;},function(D5,E5){function subtract(a,b){if(b===void 0){return F5=>subtract(a,F5);}return a-b;}D5.exports=subtract;},function(G5,H5,I5){const J5=I5(3);function tail(K5){return J5(1,K5);}G5.exports=tail;},function(L5,M5,N5){const O5=N5(1);function take(P5,a){if(a===void 0){return Q5=>take(P5,Q5);}else if(typeof a==="string"){return a.slice(0,P5);}return O5(a,0,P5);}L5.exports=take;},function(R5,S5,T5){const U5=T5(1);function takeLast(V5,a){if(a===void 0){return W5=>takeLast(V5,W5);}const X5=a.length;V5=V5>X5?X5:V5;if(typeof a==="string"){return a.slice(X5-V5);}V5=X5-V5;return U5(a,V5,X5);}R5.exports=takeLast;},function(Y5,Z5){function test(a6,b6){if(b6===void 0){return c6=>test(a6,c6);}return b6.search(a6)===-1?!1:!0;}Y5.exports=test;},function(d6,e6){function toLower(f6){return f6.toLowerCase();}d6.exports=toLower;},function(g6,h6){function toUpper(i6){return i6.toUpperCase();}g6.exports=toUpper;},function(j6,k6){function trim(l6){return l6.trim();}j6.exports=trim;},function(m6,n6,o6){const p6=o6(2);function uniq(q6){let r6=-1;const s6=[];while(++r6<q6.length){const t6=q6[r6];if(!p6(t6,s6)){s6.push(t6);}}return s6;}m6.exports=uniq;},function(u6,v6){function update(w6,x6,y6){if(x6===void 0){return(z6,A6)=>update(w6,z6,A6);}else if(y6===void 0){return B6=>update(w6,x6,B6);}const C6=y6.concat();return C6.fill(x6,w6,w6+1);}u6.exports=update;},function(D6,E6){function values(F6){const G6=[];for(key in F6){G6.push(F6[key]);}return G6;}D6.exports=values;}]);});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc