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

@brigad/redux-rest-easy

Package Overview
Dependencies
Maintainers
3
Versions
35
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@brigad/redux-rest-easy - npm Package Compare versions

Comparing version 1.0.0 to 2.0.0

es/initializeNetworkHelpers.js

2

dist/react-redux.min.js

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

!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports,require("react"),require("react-redux")):"function"==typeof define&&define.amd?define(["exports","react","react-redux"],r):r(e.ReduxRestEasy={},e.React,e.ReactRedux)}(this,function(e,r,t){"use strict";r=r&&r.hasOwnProperty("default")?r.default:r;var n,o,u,c,i=function(e){return function(){var r=e.apply(this,arguments);return new Promise(function(e,t){return function n(o,u){try{var c=r[o](u),i=c.value}catch(e){return void t(e)}if(!c.done)return Promise.resolve(i).then(function(e){n("next",e)},function(e){n("throw",e)});e(i)}("next")})}},a=function(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")},s=Object.assign||function(e){for(var r=1;arguments.length>r;r++){var t=arguments[r];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},f=function(e,r){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!r||"object"!=typeof r&&"function"!=typeof r?e:r},l=function(e){return function(r,n){for(var o=arguments.length,u=Array(o>2?o-2:0),c=2;o>c;c++)u[c-2]=arguments[c];return t.connect.apply(void 0,[r,n&&"function"==typeof n?function(){var r=n.apply(void 0,arguments);return Object.keys(r).reduce(function(t,n){var o;return s({},t,((o={})[n]=function(){var t=r[n].apply(r,arguments);return t&&t.__actionName&&t.__requestURL&&(e(t.__actionName,t.__requestURL),delete t.__actionName,delete t.__requestURL),t},o))},{})}:{}].concat(u))}},d=function(e,r){return function(t){return{type:e,resourceName:r,resourceId:t}}},p=function(e,r,t){return"@@rest-easy/"+e+"/"+r+"/"+t.toUpperCase()},h=function(e){var r=function(e){return{INVALIDATE_RESOURCE:p(e,"@invalidate","INVALIDATE_RESOURCE"),INVALIDATE_ID:p(e,"@invalidate","INVALIDATE_ID"),RESET_RESOURCE:p(e,"@reset","RESET_RESOURCE")}}(e),t=r.INVALIDATE_ID,n=r.RESET_RESOURCE;return{resource:{invalidate:d(r.INVALIDATE_RESOURCE,e),invalidateId:d(t,e),reset:d(n,e)}}},y=function(e){return function(r,t,n,o){return{type:e,url:r,resourceId:t,payload:n&&Object.keys(n).length?n:void 0,principalResourceIds:"string"==typeof o?[o]:o}}},v=function(e,r){var t=function(e,r){return{REQUEST:p(e,r,"REQUEST"),RECEIVE:p(e,r,"RECEIVE"),FAIL:p(e,r,"FAIL"),RECEIVE_FROM_CACHE:p(e,r,"RECEIVE_FROM_CACHE")}}(e,r),n=t.RECEIVE,o=t.FAIL,u=t.RECEIVE_FROM_CACHE;return{REQUEST:y(t.REQUEST),RECEIVE:y(n),FAIL:y(o),RECEIVE_FROM_CACHE:y(u)}},b={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},g=function(e){throw{name:"SyntaxError",message:e,at:n,text:u}},A=function(e){return e&&e!==o&&g("Expected '"+e+"' instead of '"+o+"'"),o=u.charAt(n),n+=1,o},_=function(){var e,r="";for("-"===o&&(r="-",A("-"));o>="0"&&"9">=o;)r+=o,A();if("."===o)for(r+=".";A()&&o>="0"&&"9">=o;)r+=o;if("e"===o||"E"===o)for(r+=o,A(),"-"!==o&&"+"!==o||(r+=o,A());o>="0"&&"9">=o;)r+=o,A();if(isFinite(e=+r))return e;g("Bad number")},E=function(){var e,r,t,n="";if('"'===o)for(;A();){if('"'===o)return A(),n;if("\\"===o)if(A(),"u"===o){for(t=0,r=0;4>r&&(e=parseInt(A(),16),isFinite(e));r+=1)t=16*t+e;n+=String.fromCharCode(t)}else{if("string"!=typeof b[o])break;n+=b[o]}else n+=o}g("Bad string")},j=function(){for(;o&&" ">=o;)A()};c=function(){switch(j(),o){case"{":return function(){var e,r={};if("{"===o){if(A("{"),j(),"}"===o)return A("}"),r;for(;o;){if(e=E(),j(),A(":"),Object.hasOwnProperty.call(r,e)&&g('Duplicate key "'+e+'"'),r[e]=c(),j(),"}"===o)return A("}"),r;A(","),j()}}g("Bad object")}();case"[":return function(){var e=[];if("["===o){if(A("["),j(),"]"===o)return A("]"),e;for(;o;){if(e.push(c()),j(),"]"===o)return A("]"),e;A(","),j()}}g("Bad array")}();case'"':return E();case"-":return _();default:return"0">o||o>"9"?function(){switch(o){case"t":return A("t"),A("r"),A("u"),A("e"),!0;case"f":return A("f"),A("a"),A("l"),A("s"),A("e"),!1;case"n":return A("n"),A("u"),A("l"),A("l"),null}g("Unexpected '"+o+"'")}():_()}};var m,C,O,I=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,S={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};function q(e){return I.lastIndex=0,I.test(e)?'"'+e.replace(I,function(e){var r=S[e];return"string"==typeof r?r:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}var R=void 0!==JSON?JSON:{parse:function(e,r){var t;return u=e,n=0,o=" ",t=c(),j(),o&&g("Syntax error"),"function"==typeof r?function e(t,n){var o,u,c=t[n];if(c&&"object"==typeof c)for(o in c)Object.prototype.hasOwnProperty.call(c,o)&&(void 0!==(u=e(c,o))?c[o]=u:delete c[o]);return r.call(t,n,c)}({"":t},""):t},stringify:function(e,r,t){var n;if(m="",C="","number"==typeof t)for(n=0;t>n;n+=1)C+=" ";else"string"==typeof t&&(C=t);if(O=r,r&&"function"!=typeof r&&("object"!=typeof r||"number"!=typeof r.length))throw Error("JSON.stringify");return function e(r,t){var n,o,u,c,i,a=m,s=t[r];switch(s&&"object"==typeof s&&"function"==typeof s.toJSON&&(s=s.toJSON(r)),"function"==typeof O&&(s=O.call(t,r,s)),typeof s){case"string":return q(s);case"number":return isFinite(s)?s+"":"null";case"boolean":case"null":return s+"";case"object":if(!s)return"null";if(m+=C,i=[],"[object Array]"===Object.prototype.toString.apply(s)){for(c=s.length,n=0;c>n;n+=1)i[n]=e(n,s)||"null";return u=0===i.length?"[]":m?"[\n"+m+i.join(",\n"+m)+"\n"+a+"]":"["+i.join(",")+"]",m=a,u}if(O&&"object"==typeof O)for(c=O.length,n=0;c>n;n+=1)"string"==typeof(o=O[n])&&(u=e(o,s))&&i.push(q(o)+(m?": ":":")+u);else for(o in s)Object.prototype.hasOwnProperty.call(s,o)&&(u=e(o,s))&&i.push(q(o)+(m?": ":":")+u);return u=0===i.length?"{}":m?"{\n"+m+i.join(",\n"+m)+"\n"+a+"}":"{"+i.join(",")+"}",m=a,u}}("",{"":e})}},w=function(e,r){r||(r={}),"function"==typeof r&&(r={cmp:r});var t=r.space||"";"number"==typeof t&&(t=Array(t+1).join(" "));var n,o="boolean"==typeof r.cycles&&r.cycles,u=r.replacer||function(e,r){return r},c=r.cmp&&(n=r.cmp,function(e){return function(r,t){return n({key:r,value:e[r]},{key:t,value:e[t]})}}),i=[];return function e(r,n,a,s){var f=t?"\n"+Array(s+1).join(t):"",l=t?": ":":";if(a&&a.toJSON&&"function"==typeof a.toJSON&&(a=a.toJSON()),void 0!==(a=u.call(r,n,a))){if("object"!=typeof a||null===a)return R.stringify(a);if(T(a)){for(var d=[],p=0;a.length>p;p++){var h=e(a,p,a[p],s+1)||R.stringify(null);d.push(f+t+h)}return"["+d.join(",")+f+"]"}if(-1!==i.indexOf(a)){if(o)return R.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}i.push(a);var y=x(a).sort(c&&c(a));for(d=[],p=0;y.length>p;p++){var v=e(a,n=y[p],a[n],s+1);if(v){var b=R.stringify(n)+l+v;d.push(f+t+b)}}return i.splice(i.indexOf(a),1),"{"+d.join(",")+f+"}"}}({"":e},"",e,0)},T=Array.isArray||function(e){return"[object Array]"==={}.toString.call(e)},x=Object.keys||function(e){var r=Object.prototype.hasOwnProperty||function(){return!0},t=[];for(var n in e)r.call(e,n)&&t.push(n);return t},N="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function P(e,r){return e(r={exports:{}},r.exports),r.exports}var k=P(function(e,r){var t=Object.prototype.hasOwnProperty,n=function(){for(var e=[],r=0;256>r;++r)e.push("%"+((16>r?"0":"")+r.toString(16)).toUpperCase());return e}();r.arrayToObject=function(e,r){for(var t=r&&r.plainObjects?Object.create(null):{},n=0;e.length>n;++n)void 0!==e[n]&&(t[n]=e[n]);return t},r.merge=function(e,n,o){if(!n)return e;if("object"!=typeof n){if(Array.isArray(e))e.push(n);else{if("object"!=typeof e)return[e,n];(o.plainObjects||o.allowPrototypes||!t.call(Object.prototype,n))&&(e[n]=!0)}return e}if("object"!=typeof e)return[e].concat(n);var u=e;return Array.isArray(e)&&!Array.isArray(n)&&(u=r.arrayToObject(e,o)),Array.isArray(e)&&Array.isArray(n)?(n.forEach(function(n,u){t.call(e,u)?e[u]&&"object"==typeof e[u]?e[u]=r.merge(e[u],n,o):e.push(n):e[u]=n}),e):Object.keys(n).reduce(function(e,u){var c=n[u];return e[u]=t.call(e,u)?r.merge(e[u],c,o):c,e},u)},r.assign=function(e,r){return Object.keys(r).reduce(function(e,t){return e[t]=r[t],e},e)},r.decode=function(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(r){return e}},r.encode=function(e){if(0===e.length)return e;for(var r="string"==typeof e?e:e+"",t="",o=0;r.length>o;++o){var u=r.charCodeAt(o);45!==u&&46!==u&&95!==u&&126!==u&&(48>u||u>57)&&(65>u||u>90)&&(97>u||u>122)?128>u?t+=n[u]:2048>u?t+=n[192|u>>6]+n[128|63&u]:u>=55296&&57344>u?(u=65536+((1023&u)<<10|1023&r.charCodeAt(o+=1)),t+=n[240|u>>18]+n[128|u>>12&63]+n[128|u>>6&63]+n[128|63&u]):t+=n[224|u>>12]+n[128|u>>6&63]+n[128|63&u]:t+=r.charAt(o)}return t},r.compact=function(e){for(var r=[{obj:{o:e},prop:"o"}],t=[],n=0;r.length>n;++n)for(var o=r[n],u=o.obj[o.prop],c=Object.keys(u),i=0;c.length>i;++i){var a=c[i],s=u[a];"object"==typeof s&&null!==s&&-1===t.indexOf(s)&&(r.push({obj:u,prop:a}),t.push(s))}return function(e){for(var r;e.length;){var t=e.pop();if(Array.isArray(r=t.obj[t.prop])){for(var n=[],o=0;r.length>o;++o)void 0!==r[o]&&n.push(r[o]);t.obj[t.prop]=n}}return r}(r)},r.isRegExp=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},r.isBuffer=function(e){return null!=e&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))}}),L=String.prototype.replace,U=/%20/g,F={default:"RFC3986",formatters:{RFC1738:function(e){return L.call(e,U,"+")},RFC3986:function(e){return e}},RFC1738:"RFC1738",RFC3986:"RFC3986"},D={brackets:function(e){return e+"[]"},indices:function(e,r){return e+"["+r+"]"},repeat:function(e){return e}},z=Date.prototype.toISOString,V={delimiter:"&",encode:!0,encoder:k.encode,encodeValuesOnly:!1,serializeDate:function(e){return z.call(e)},skipNulls:!1,strictNullHandling:!1},H=function e(r,t,n,o,u,c,i,a,s,f,l,d){var p=r;if("function"==typeof i)p=i(t,p);else if(p instanceof Date)p=f(p);else if(null===p){if(o)return c&&!d?c(t,V.encoder):t;p=""}if("string"==typeof p||"number"==typeof p||"boolean"==typeof p||k.isBuffer(p))return c?[l(d?t:c(t,V.encoder))+"="+l(c(p,V.encoder))]:[l(t)+"="+l(p+"")];var h,y=[];if(void 0===p)return y;if(Array.isArray(i))h=i;else{var v=Object.keys(p);h=a?v.sort(a):v}for(var b=0;h.length>b;++b){var g=h[b];u&&null===p[g]||(y=y.concat(e(p[g],Array.isArray(p)?n(t,g):t+(s?"."+g:"["+g+"]"),n,o,u,c,i,a,s,f,l,d)))}return y},B=function(e,r){var t=e,n=r?k.assign({},r):{};if(null!=n.encoder&&"function"!=typeof n.encoder)throw new TypeError("Encoder has to be a function.");var o=void 0===n.delimiter?V.delimiter:n.delimiter,u="boolean"==typeof n.strictNullHandling?n.strictNullHandling:V.strictNullHandling,c="boolean"==typeof n.skipNulls?n.skipNulls:V.skipNulls,i="boolean"==typeof n.encode?n.encode:V.encode,a="function"==typeof n.encoder?n.encoder:V.encoder,s="function"==typeof n.sort?n.sort:null,f=void 0!==n.allowDots&&n.allowDots,l="function"==typeof n.serializeDate?n.serializeDate:V.serializeDate,d="boolean"==typeof n.encodeValuesOnly?n.encodeValuesOnly:V.encodeValuesOnly;if(void 0===n.format)n.format=F.default;else if(!Object.prototype.hasOwnProperty.call(F.formatters,n.format))throw new TypeError("Unknown format option provided.");var p,h,y=F.formatters[n.format];"function"==typeof n.filter?t=(h=n.filter)("",t):Array.isArray(n.filter)&&(p=h=n.filter);var v=[];if("object"!=typeof t||null===t)return"";var b=D[n.arrayFormat in D?n.arrayFormat:"indices"in n?n.indices?"indices":"repeat":"indices"];p||(p=Object.keys(t)),s&&p.sort(s);for(var g=0;p.length>g;++g){var A=p[g];c&&null===t[A]||(v=v.concat(H(t[A],A,b,u,c,i?a:null,h,s,f,l,y,d)))}var _=v.join(o);return _.length>0?(!0===n.addQueryPrefix?"?":"")+_:""},M=function(e){var r,t=(r=e)&&Object.keys(r)?B(r):"";return t?"?"+t:""},Q=function(e){return e&&e.restEasy?e.restEasy:(console.error('There doesn\'t seem to be a "restEasy" key in your state. In doubt, double check the docs on reducers.'),null)},J=function(e,r){return new Date-new Date(e)>1e3*r},G={requestGET:function(){return{method:"GET",headers:{Accept:"application/json"}}},requestPATCH:function(e){return{method:"PATCH",headers:{Accept:"application/json","Content-Type":"application/json"},body:e}},requestPUT:function(e){return{method:"PUT",headers:{Accept:"application/json","Content-Type":"application/json"},body:e}},requestPOST:function(e){return{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:e}},requestDELETE:function(){return{method:"DELETE",headers:{Accept:"application/json"}}},handleStatusCode:function(e){if(e){if(e.status>=200&&300>e.status)return e;var r=Error(e.statusText);throw r.response=e,r}return null},handleError:function(){return e=i(function*(e,r){try{if(e&&e.response){var t=yield e.response.json();r||alert(t.message)}else console.error(e)}catch(e){console.error(e)}}),function(r,t){return e.apply(this,arguments)};var e}},K=void 0,$=function(){return K||G},Y=function(e){for(var r=arguments.length,t=Array(r>1?r-1:0),n=1;r>n;n++)t[n-1]=arguments[n];if(e&&"function"==typeof e)return e.apply(void 0,t)},W=function(e,r,t,n,o,u){return function(e,c,a){return function(){var s,f=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},l=f.query,d=void 0===l?{}:l,p=f.body,h=void 0===p?{}:p,y=f.urlParams,v=void 0===y?{}:y,b=f.onSuccess,g=f.onError,A=function(e,r){var t={};for(var n in e)0>r.indexOf(n)&&Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}(f,["query","body","urlParams","onSuccess","onError"]);return s=i(function*(i,s){var f=$(),l=f.handleError,p=f.handleStatusCode;i(r.REQUEST(c,a));try{var y=(yield Y(n,v,d,h,A,i))||h,_=yield fetch(e,function(){var e=$();return{GET:e.requestGET,PATCH:e.requestPATCH,PUT:e.requestPUT,POST:e.requestPOST,DELETE:e.requestDELETE}}()[t](y));p(_);var E=204!==_.status?yield _.json():{},j=o?o(E,Q(s()).resources,v,d,y,A):{entities:E},m=j.entities;return i(r.RECEIVE(c,a,m,j.result)),yield Y(u,m||{},v,d,y,A,i),Y(b,m||{},A),{normalizedPayload:m||{},otherArgs:A}}catch(e){return i(r.FAIL(c,a)),l(e,i),Y(g,e),{error:e}}}),function(e,r){return s.apply(this,arguments)}}}},X=function(e,r,t,n){var o=t[n],u=o.method,c=o.url,i=o.beforeHook,a=o.normalizer,s=o.afterHook,f=v(e,n),l=W(0,f,u,i,a,s);return function(t){return function(o,i){var a=Q(i()),s=t||{},d=s.urlParams,p=s.query,h=function(e){var r=("string"!=typeof e?e():e).split("/").reverse(),t=r.findIndex(function(e){return e.startsWith("::")});return-1!==t?r.length-1-t:-1}(c),y=function(e,r,t){var n="string"!=typeof e?e():e;r&&Object.keys(r).forEach(function(e){n=n.replace("::"+e,r[e]).replace(":"+e,r[e])});var o=t?M(JSON.parse(w(t))):"";return""+n+o}(c,d,p),v=function(e,r){return(e||"")+":"+(r||"")}(n,y),b=function(e,r){if(!e||!r&&0!==r||-1===r)return null;for(var t=0,n=0;r>n;n+=1)t=e.indexOf("/",t+1);var o=e.indexOf("/",t+1);return e.substr(t+1,-1!==o?o-t-1:e.length)}(v,h),g=void 0;(function(e,r){return!(e&&r&&e.requests&&e.requests[r]&&!e.requests[r].endedAt)})(a,v)&&function(e,r,t,n){if(!("GET"===r&&e&&t&&e.requests&&e.requests[t]))return!0;var o=e.requests[t];return!o.hasSucceeded||o.didInvalidate||J(o.endedAt,n)}(a,u,v,r)&&(g=function(e,r,t,n,o){return!!("GET"===r&&e&&e.requests&&t&&null!==n)&&Object.values(e.requests).some(function(e){var r=e.endedAt,u=e.payloadIds;return e.hasSucceeded&&!e.didInvalidate&&(t===e.resourceName&&n===e.resourceId||u&&u[t]&&u[t].includes(n))&&!J(r,o)})}(a,u,e,b,r)?function(){var r,t;return o(f.RECEIVE_FROM_CACHE(v,b,((t={})[e]=((r={})[b]=null,r),t),[b]))}:function(){return o(l(y,v,b)(t))});var A=g?g():{};return A.__actionName=n,A.__requestURL=v,A}}},Z=function(e,r,t,n){var o,u=function(e){return{INVALIDATE_REQUEST:p(e,"@invalidate","INVALIDATE_REQUEST")}}(e).INVALIDATE_REQUEST;return(o={})[n]={perform:X(e,r,t,n),invalidate:function(e,r){return function(t){return{type:e,url:t,resourceName:r}}}(u,e)},o},ee="[object Object]";var re,te,ne=Object.prototype,oe=Function.prototype.toString,ue=ne.hasOwnProperty,ce=oe.call(Object),ie=ne.toString,ae=(re=Object.getPrototypeOf,te=Object,function(e){return re(te(e))});var se,fe=function(e){if(!function(e){return!!e&&"object"==typeof e}(e)||ie.call(e)!=ee||function(e){var r=!1;if(null!=e&&"function"!=typeof e.toString)try{r=!!(e+"")}catch(e){}return r}(e))return!1;var r=ae(e);if(null===r)return!0;var t=ue.call(r,"constructor")&&r.constructor;return"function"==typeof t&&t instanceof t&&oe.call(t)==ce},le=function(e){return function(r){throw Error("redux-rest-easy: "+e+" "+r)}},de=function(e){return"string"==typeof e},pe=function(e){return"function"==typeof e},he=function(e){return void 0!==e},ye=["method","url"],ve=[].concat(ye,["beforeHook","normalizer","afterHook"]),be=["GET","POST","PATCH","PUT","DELETE"],ge=function(e){return e+" >"},Ae=function(e,r){return e+' "'+r+'" is invalid. Expected a valid function.'},_e=function(e,r){if(r){if(!fe(r)||!Object.keys(r).length)le(ge(e)+" createResource >")("You have to provide a valid actions configuration.");Object.keys(r).forEach(function(t){var n=le(ge(e)+" "+function(e){return e+" >"}(t)+" createResource >"),o=r[t],u=Object.keys(o);ye.forEach(function(e){u.includes(e)||n('Key "'+e+'" is missing.')}),u.forEach(function(e){ve.includes(e)||n(function(e){return'Unknown key "'+e+"."}(e))});var c=o.method,i=o.url,a=o.beforeHook,s=o.normalizer,f=o.afterHook;de(c)&&be.includes(c)||n(function(e){return'Method "'+e+'" is invalid. Expected one of: '+be.join(", ")+"."}(c)),i&&(de(i)||pe(i))||n(function(e){return'URL "'+e+'" is invalid. Expected a valid URL.'}(i)),he(a)&&!pe(a)&&n(Ae("beforeHook",a)),he(s)&&!pe(s)&&n(Ae("normalizer",s)),he(f)&&!pe(f)&&n(Ae("afterHook",f))})}},Ee=function(e){return void 0!==e},je=["cacheLifetime","denormalizer"],me=function(e,r){var t,n=(t=function(e){return e+" >"}(e||"[no resource name]")+" createResource >",function(e){throw Error("redux-rest-easy: "+t+" "+e)});if(e&&"string"==typeof e||n("You have to provide a valid resource name."),r){fe(r)&&Object.keys(r).length||n("You have to provide a valid resource configuration (or not at all)."),Object.keys(r).forEach(function(e){je.includes(e)||n(function(e){return'Unknown key "'+e+'" in resource config.'}(e))});var o=r.cacheLifetime,u=r.denormalizer;!Ee(o)||function(e){return"number"==typeof e}(o)&&o>=0||n(function(e){return'cacheLifetime "'+e+'" in resource config is invalid. Expected a number between 0 and Infinity.'}(o)),Ee(u)&&!function(e){return"function"==typeof e}(u)&&n(function(e,r){return e+' "'+r+'" in resource config is invalid. Expected a valid function.'}("denormalizer",u))}},Ce=P(function(e,r){function t(e,r){return e===r}function n(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,n=null,o=null;return function(){return function(e,r,t){if(null===r||null===t||r.length!==t.length)return!1;for(var n=r.length,o=0;n>o;o++)if(!e(r[o],t[o]))return!1;return!0}(r,n,arguments)||(o=e.apply(null,arguments)),n=arguments,o}}function o(e){for(var r=arguments.length,t=Array(r>1?r-1:0),o=1;r>o;o++)t[o-1]=arguments[o];return function(){for(var r=arguments.length,o=Array(r),u=0;r>u;u++)o[u]=arguments[u];var c=0,i=o.pop(),a=function(e){var r=Array.isArray(e[0])?e[0]:e;if(!r.every(function(e){return"function"==typeof e})){var t=r.map(function(e){return typeof e}).join(", ");throw Error("Selector creators expect all input-selectors to be functions, instead received the following types: ["+t+"]")}return r}(o),s=e.apply(void 0,[function(){return c++,i.apply(null,arguments)}].concat(t)),f=n(function(){for(var e=[],r=a.length,t=0;r>t;t++)e.push(a[t].apply(null,arguments));return s.apply(null,e)});return f.resultFunc=i,f.recomputations=function(){return c},f.resetRecomputations=function(){return c=0},f}}r.__esModule=!0,r.defaultMemoize=n,r.createSelectorCreator=o,r.createStructuredSelector=function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:u;if("object"!=typeof e)throw Error("createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);var t=Object.keys(e);return r(t.map(function(r){return e[r]}),function(){for(var e=arguments.length,r=Array(e),n=0;e>n;n++)r[n]=arguments[n];return r.reduce(function(e,r,n){return e[t[n]]=r,e},{})})};var u=r.createSelector=o(n)});(se=Ce)&&se.__esModule&&Object.prototype.hasOwnProperty.call(se,"default");var Oe=Ce.createSelectorCreator,Ie=Ce.createSelector,Se=function(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")},qe=function(){function e(){Se(this,e),this._cache={}}return e.prototype.set=function(e,r){this._cache[e]=r},e.prototype.get=function(e){return this._cache[e]},e.prototype.remove=function(e){delete this._cache[e]},e.prototype.clear=function(){this._cache={}},e}();function Re(){for(var e=arguments.length,r=Array(e),t=0;e>t;t++)r[t]=arguments[t];var n=qe;return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=void 0,u=void 0;"function"==typeof t?(console.warn('[re-reselect] Deprecation warning: "selectorCreator" argument is discouraged and will be removed in the upcoming major release. Please use "options.selectorCreator" instead.'),o=new n,u=t):(o=t.cacheObject||new n,u=t.selectorCreator||Ie);var c=function(){var t=e.apply(void 0,arguments);if("string"==typeof t||"number"==typeof t){var n=o.get(t);return void 0===n&&(n=u.apply(void 0,r),o.set(t,n)),n.apply(void 0,arguments)}};return c.getMatchingSelector=function(){var r=e.apply(void 0,arguments);return o.get(r)},c.removeMatchingSelector=function(){var r=e.apply(void 0,arguments);o.remove(r)},c.clearCache=function(){o.clear()},c.resultFunc=r[r.length-1],c}}var we=function(e){return e.split(":")[0]},Te=function(e,r,t){return t?t.__requestURLsByActionKey?t.__requestURLsByActionKey[r]:(console.error("You seem to have forgotten to use redux-rest-easy's connect on a Component which requested "+e+"."+r),""):(console.error("You seem to have forgotten to pass ownProps to a selector related to "+e+"."+r),"")},xe={selectorCreator:Oe(function(e){var r=null;return function(){return r||(r=e.apply(void 0,arguments)),r}})},Ne=function(){return xe},Pe=function(e,r,t){return r?Object.keys(r).reduce(function(n,o){var u;return s({},n,((u={})[o]=o===e?t:Object.keys(r[o]||{}),u))},{}):{}},ke=P(function(e,r){!function(t,n){var o={version:"2.1.2",x86:{},x64:{}};function u(e,r){return(65535&e)*r+(((e>>>16)*r&65535)<<16)}function c(e,r){return e<<r|e>>>32-r}function i(e){return e=u(e^=e>>>16,2246822507),e=u(e^=e>>>13,3266489909),e^=e>>>16}function a(e,r){var t=[0,0,0,0];return t[3]+=(e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]])[3]+(r=[r[0]>>>16,65535&r[0],r[1]>>>16,65535&r[1]])[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]+r[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]+r[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]+r[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function s(e,r){var t=[0,0,0,0];return t[3]+=(e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]])[3]*(r=[r[0]>>>16,65535&r[0],r[1]>>>16,65535&r[1]])[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]*r[3],t[1]+=t[2]>>>16,t[2]&=65535,t[2]+=e[3]*r[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]*r[3],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[2]*r[2],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[3]*r[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]*r[3]+e[1]*r[2]+e[2]*r[1]+e[3]*r[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function f(e,r){return 32===(r%=64)?[e[1],e[0]]:32>r?[e[0]<<r|e[1]>>>32-r,e[1]<<r|e[0]>>>32-r]:[e[1]<<(r-=32)|e[0]>>>32-r,e[0]<<r|e[1]>>>32-r]}function l(e,r){return 0===(r%=64)?e:32>r?[e[0]<<r|e[1]>>>32-r,e[1]<<r]:[e[1]<<r-32,0]}function d(e,r){return[e[0]^r[0],e[1]^r[1]]}function p(e){return e=d(e=s(e=d(e=s(e=d(e,[0,e[0]>>>1]),[4283543511,3981806797]),[0,e[0]>>>1]),[3301882366,444984403]),[0,e[0]>>>1])}o.x86.hash32=function(e,r){for(var t=(e=e||"").length%4,n=e.length-t,o=r=r||0,a=0,s=3432918353,f=461845907,l=0;n>l;l+=4)o=u(o=c(o^=a=u(a=c(a=u(a=255&e.charCodeAt(l)|(255&e.charCodeAt(l+1))<<8|(255&e.charCodeAt(l+2))<<16|(255&e.charCodeAt(l+3))<<24,s),15),f),13),5)+3864292196;switch(a=0,t){case 3:a^=(255&e.charCodeAt(l+2))<<16;case 2:a^=(255&e.charCodeAt(l+1))<<8;case 1:o^=a=u(a=c(a=u(a^=255&e.charCodeAt(l),s),15),f)}return(o=i(o^=e.length))>>>0},o.x86.hash128=function(e,r){for(var t=(e=e||"").length%16,n=e.length-t,o=r=r||0,a=r,s=r,f=r,l=0,d=0,p=0,h=0,y=597399067,v=2869860233,b=951274213,g=2716044179,A=0;n>A;A+=16)l=255&e.charCodeAt(A)|(255&e.charCodeAt(A+1))<<8|(255&e.charCodeAt(A+2))<<16|(255&e.charCodeAt(A+3))<<24,d=255&e.charCodeAt(A+4)|(255&e.charCodeAt(A+5))<<8|(255&e.charCodeAt(A+6))<<16|(255&e.charCodeAt(A+7))<<24,p=255&e.charCodeAt(A+8)|(255&e.charCodeAt(A+9))<<8|(255&e.charCodeAt(A+10))<<16|(255&e.charCodeAt(A+11))<<24,h=255&e.charCodeAt(A+12)|(255&e.charCodeAt(A+13))<<8|(255&e.charCodeAt(A+14))<<16|(255&e.charCodeAt(A+15))<<24,o=c(o^=l=u(l=c(l=u(l,y),15),v),19),o=u(o+=a,5)+1444728091,a=c(a^=d=u(d=c(d=u(d,v),16),b),17),a=u(a+=s,5)+197830471,s=c(s^=p=u(p=c(p=u(p,b),17),g),15),s=u(s+=f,5)+2530024501,f=c(f^=h=u(h=c(h=u(h,g),18),y),13),f=u(f+=o,5)+850148119;switch(l=0,d=0,p=0,h=0,t){case 15:h^=e.charCodeAt(A+14)<<16;case 14:h^=e.charCodeAt(A+13)<<8;case 13:f^=h=u(h=c(h=u(h^=e.charCodeAt(A+12),g),18),y);case 12:p^=e.charCodeAt(A+11)<<24;case 11:p^=e.charCodeAt(A+10)<<16;case 10:p^=e.charCodeAt(A+9)<<8;case 9:s^=p=u(p=c(p=u(p^=e.charCodeAt(A+8),b),17),g);case 8:d^=e.charCodeAt(A+7)<<24;case 7:d^=e.charCodeAt(A+6)<<16;case 6:d^=e.charCodeAt(A+5)<<8;case 5:a^=d=u(d=c(d=u(d^=e.charCodeAt(A+4),v),16),b);case 4:l^=e.charCodeAt(A+3)<<24;case 3:l^=e.charCodeAt(A+2)<<16;case 2:l^=e.charCodeAt(A+1)<<8;case 1:o^=l=u(l=c(l=u(l^=e.charCodeAt(A),y),15),v)}return o^=e.length,o+=a^=e.length,o+=s^=e.length,a+=o+=f^=e.length,s+=o,f+=o,o=i(o),o+=a=i(a),o+=s=i(s),a+=o+=f=i(f),s+=o,f+=o,("00000000"+(o>>>0).toString(16)).slice(-8)+("00000000"+(a>>>0).toString(16)).slice(-8)+("00000000"+(s>>>0).toString(16)).slice(-8)+("00000000"+(f>>>0).toString(16)).slice(-8)},o.x64.hash128=function(e,r){for(var t=(e=e||"").length%16,n=e.length-t,o=[0,r=r||0],u=[0,r],c=[0,0],i=[0,0],h=[2277735313,289559509],y=[1291169091,658871167],v=0;n>v;v+=16)c=[255&e.charCodeAt(v+4)|(255&e.charCodeAt(v+5))<<8|(255&e.charCodeAt(v+6))<<16|(255&e.charCodeAt(v+7))<<24,255&e.charCodeAt(v)|(255&e.charCodeAt(v+1))<<8|(255&e.charCodeAt(v+2))<<16|(255&e.charCodeAt(v+3))<<24],i=[255&e.charCodeAt(v+12)|(255&e.charCodeAt(v+13))<<8|(255&e.charCodeAt(v+14))<<16|(255&e.charCodeAt(v+15))<<24,255&e.charCodeAt(v+8)|(255&e.charCodeAt(v+9))<<8|(255&e.charCodeAt(v+10))<<16|(255&e.charCodeAt(v+11))<<24],o=a(s(o=a(o=f(o=d(o,c=s(c=f(c=s(c,h),31),y)),27),u),[0,5]),[0,1390208809]),u=a(s(u=a(u=f(u=d(u,i=s(i=f(i=s(i,y),33),h)),31),o),[0,5]),[0,944331445]);switch(c=[0,0],i=[0,0],t){case 15:i=d(i,l([0,e.charCodeAt(v+14)],48));case 14:i=d(i,l([0,e.charCodeAt(v+13)],40));case 13:i=d(i,l([0,e.charCodeAt(v+12)],32));case 12:i=d(i,l([0,e.charCodeAt(v+11)],24));case 11:i=d(i,l([0,e.charCodeAt(v+10)],16));case 10:i=d(i,l([0,e.charCodeAt(v+9)],8));case 9:u=d(u,i=s(i=f(i=s(i=d(i,[0,e.charCodeAt(v+8)]),y),33),h));case 8:c=d(c,l([0,e.charCodeAt(v+7)],56));case 7:c=d(c,l([0,e.charCodeAt(v+6)],48));case 6:c=d(c,l([0,e.charCodeAt(v+5)],40));case 5:c=d(c,l([0,e.charCodeAt(v+4)],32));case 4:c=d(c,l([0,e.charCodeAt(v+3)],24));case 3:c=d(c,l([0,e.charCodeAt(v+2)],16));case 2:c=d(c,l([0,e.charCodeAt(v+1)],8));case 1:o=d(o,c=s(c=f(c=s(c=d(c,[0,e.charCodeAt(v)]),h),31),y))}return o=d(o,[0,e.length]),u=a(u=d(u,[0,e.length]),o=a(o,u)),o=p(o),u=a(u=p(u),o=a(o,u)),("00000000"+(o[0]>>>0).toString(16)).slice(-8)+("00000000"+(o[1]>>>0).toString(16)).slice(-8)+("00000000"+(u[0]>>>0).toString(16)).slice(-8)+("00000000"+(u[1]>>>0).toString(16)).slice(-8)},e.exports&&(r=e.exports=o),r.murmurHash3=o}()}),Le=ke,Ue=P(function(e){e.exports={v3:Le},function(){throw Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}.main===e&&console.log(e.exports.v3)}).v3,Fe=function(e){return Ue.x64.hash128(w(e||null))},De=Fe([]),ze={empty:De,requests:{},resources:{}},Ve=s({},ze),He=function(e,r,t,n,o){var u,c,i=Pe(r,n,o),a=Object.keys(i).reduce(function(r,n){var o;return s({},r,((o={})[n]=e&&e.requests&&e.requests[t]&&e.requests[t].payloadIds&&e.requests[t].payloadIds[n]?Fe(e.requests[t].payloadIds[n]):De,o))},{});Ve=s({},Ve,{requests:s({},Ve.requests,(u={},u[t]=a,u)),resources:s({},Ve.resources,(c={_getResourcesHash:function(){return Fe(e.resources)}},c[r]=e.resources&&e.resources[r]?Fe(e.resources[r]):De,c))})},Be=function(){return Ve.empty},Me=function(e,r){return Ve.requests[e]?Ve.requests[e][r]:De},Qe=function(e){return Ve.resources[e]?Ve.resources[e]:De},Je=[],Ge=function(e,r){return("number"==typeof e?""+e:e)===("number"==typeof r?""+r:r)},Ke=function(e,r,t){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:-1;return!!e.requests&&Object.entries(e.requests).some(function(e){var o=e[1],u=o.resourceName,c=o.resourceId,i=o.endedAt;return we(e[0])===t&&u===r&&(-1===n||null!==c&&Ge(c,n))&&!i})},$e=function(e,r,t,n){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1,u=e.requests&&Object.entries(e.requests).filter(function(e){var n=e[1],u=n.resourceName,c=n.resourceId,i=n.endedAt,a=n.payloadIds;return we(e[0])===t&&u===r&&(-1===o||null!==c&&Ge(c,o)||!!i&&a&&a[r]&&a[r].includes(o))}).map(function(e){return e[1]});return!(!u||!u.length)&&u.reduce(function(e,r){return r.endedAt&&e.endedAt&&r.endedAt>e.endedAt?r:e},u[0])[n]},Ye=function(e,r){return e.resources&&e.resources[r]?e.resources[r]:null},We=function(e,r,t){return e.requests&&e.requests[t]&&e.requests[t].payloadIds&&e.requests[t].payloadIds[r]?e.requests[t].payloadIds[r]:null},Xe=Re(function(e){return e.resources},Ye,We,function(e,r,t,n){return n},function(e,r,t,n,o){return o},function(e,r,t,n,o){return r&&t?n&&o?o(t,e):t.reduce(function(e,t){return[].concat(e,[r[t]])},[]):Je})(function(e,r,t,n,o){var u=Ye(e,r),c=We(e,r,t);return u&&c?n&&o?n+"-"+Object.keys(e.requests[t].payloadIds).map(function(e){return Me(t,e)+"-"+Qe(e)}).join("--"):n+"-"+Me(t,r)+"-"+Qe(r):Be()},Ne()),Ze=function(e,r){return!(!e.requests||!e.requests[r]||e.requests[r].endedAt)},er=function(e,r,t){return!!(e.requests&&e.requests[r]&&e.requests[r][t])},rr=[],tr=function(e,r){return e.resources&&e.resources[r]?e.resources[r]:null},nr=Re(function(e){return e.resources},tr,function(e,r,t){return t},function(e,r,t,n){return n},function(e,r,t,n){return r?t&&n?n(Object.keys(r),e):Object.values(r):rr})(function(e,r,t,n){return tr(e,r)?t&&n?t+"-"+(Ve.resources._getResourcesHash?Ve.resources._getResourcesHash():De):t+"-"+Qe(r):Be()},Ne()),or=function(e){var r=e.split("/");return{resourceName:r[1],actionName:r[2],caseName:r[3]}},ur=P(function(e,r){var t=200,n="__lodash_hash_undefined__",o=800,u=16,c=9007199254740991,i="[object Arguments]",a="[object AsyncFunction]",s="[object Function]",f="[object GeneratorFunction]",l="[object Null]",d="[object Object]",p="[object Proxy]",h="[object Undefined]",y=/^\[object .+?Constructor\]$/,v=/^(?:0|[1-9]\d*)$/,b={};b["[object Float32Array]"]=b["[object Float64Array]"]=b["[object Int8Array]"]=b["[object Int16Array]"]=b["[object Int32Array]"]=b["[object Uint8Array]"]=b["[object Uint8ClampedArray]"]=b["[object Uint16Array]"]=b["[object Uint32Array]"]=!0,b[i]=b["[object Array]"]=b["[object ArrayBuffer]"]=b["[object Boolean]"]=b["[object DataView]"]=b["[object Date]"]=b["[object Error]"]=b[s]=b["[object Map]"]=b["[object Number]"]=b[d]=b["[object RegExp]"]=b["[object Set]"]=b["[object String]"]=b["[object WeakMap]"]=!1;var g="object"==typeof N&&N&&N.Object===Object&&N,A="object"==typeof self&&self&&self.Object===Object&&self,_=g||A||Function("return this")(),E=r&&!r.nodeType&&r,j=E&&e&&!e.nodeType&&e,m=j&&j.exports===E,C=m&&g.process,O=function(){try{return C&&C.binding&&C.binding("util")}catch(e){}}(),I=O&&O.isTypedArray;function S(e,r){return"__proto__"==r?void 0:e[r]}var q,R,w,T=Array.prototype,x=Object.prototype,P=_["__core-js_shared__"],k=Function.prototype.toString,L=x.hasOwnProperty,U=(q=/[^.]+$/.exec(P&&P.keys&&P.keys.IE_PROTO||""))?"Symbol(src)_1."+q:"",F=x.toString,D=k.call(Object),z=RegExp("^"+k.call(L).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),V=m?_.Buffer:void 0,H=_.Symbol,B=_.Uint8Array,M=V?V.allocUnsafe:void 0,Q=(R=Object.getPrototypeOf,w=Object,function(e){return R(w(e))}),J=Object.create,G=x.propertyIsEnumerable,K=T.splice,$=H?H.toStringTag:void 0,Y=function(){try{var e=Ee(Object,"defineProperty");return e({},"",{}),e}catch(e){}}(),W=V?V.isBuffer:void 0,X=Math.max,Z=Date.now,ee=Ee(_,"Map"),re=Ee(Object,"create"),te=function(){function e(){}return function(r){if(!xe(r))return{};if(J)return J(r);e.prototype=r;var t=new e;return e.prototype=void 0,t}}();function ne(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function oe(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function ue(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function ce(e){var r=this.__data__=new oe(e);this.size=r.size}function ie(e,r){var t=Se(e),n=!t&&Ie(e),o=!t&&!n&&Re(e),u=!t&&!n&&!o&&Pe(e),c=t||n||o||u,i=c?function(e,r){for(var t=-1,n=Array(e);++t<e;)n[t]=r(t);return n}(e.length,String):[],a=i.length;for(var s in e)!r&&!L.call(e,s)||c&&("length"==s||o&&("offset"==s||"parent"==s)||u&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||je(s,a))||i.push(s);return i}function ae(e,r,t){(void 0===t||Oe(e[r],t))&&(void 0!==t||r in e)||le(e,r,t)}function se(e,r,t){var n=e[r];L.call(e,r)&&Oe(n,t)&&(void 0!==t||r in e)||le(e,r,t)}function fe(e,r){for(var t=e.length;t--;)if(Oe(e[t][0],r))return t;return-1}function le(e,r,t){"__proto__"==r&&Y?Y(e,r,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[r]=t}ne.prototype.clear=function(){this.__data__=re?re(null):{},this.size=0},ne.prototype.delete=function(e){var r=this.has(e)&&delete this.__data__[e];return this.size-=r?1:0,r},ne.prototype.get=function(e){var r=this.__data__;if(re){var t=r[e];return t===n?void 0:t}return L.call(r,e)?r[e]:void 0},ne.prototype.has=function(e){var r=this.__data__;return re?void 0!==r[e]:L.call(r,e)},ne.prototype.set=function(e,r){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=re&&void 0===r?n:r,this},oe.prototype.clear=function(){this.__data__=[],this.size=0},oe.prototype.delete=function(e){var r=this.__data__,t=fe(r,e);return t>=0&&(t==r.length-1?r.pop():K.call(r,t,1),--this.size,!0)},oe.prototype.get=function(e){var r=this.__data__,t=fe(r,e);return 0>t?void 0:r[t][1]},oe.prototype.has=function(e){return fe(this.__data__,e)>-1},oe.prototype.set=function(e,r){var t=this.__data__,n=fe(t,e);return 0>n?(++this.size,t.push([e,r])):t[n][1]=r,this},ue.prototype.clear=function(){this.size=0,this.__data__={hash:new ne,map:new(ee||oe),string:new ne}},ue.prototype.delete=function(e){var r=_e(this,e).delete(e);return this.size-=r?1:0,r},ue.prototype.get=function(e){return _e(this,e).get(e)},ue.prototype.has=function(e){return _e(this,e).has(e)},ue.prototype.set=function(e,r){var t=_e(this,e),n=t.size;return t.set(e,r),this.size+=t.size==n?0:1,this},ce.prototype.clear=function(){this.__data__=new oe,this.size=0},ce.prototype.delete=function(e){var r=this.__data__,t=r.delete(e);return this.size=r.size,t},ce.prototype.get=function(e){return this.__data__.get(e)},ce.prototype.has=function(e){return this.__data__.has(e)},ce.prototype.set=function(e,r){var n=this.__data__;if(n instanceof oe){var o=n.__data__;if(!ee||t-1>o.length)return o.push([e,r]),this.size=++n.size,this;n=this.__data__=new ue(o)}return n.set(e,r),this.size=n.size,this};var de,pe=function(e,r,t){for(var n=-1,o=Object(e),u=t(e),c=u.length;c--;){var i=u[de?c:++n];if(!1===r(o[i],i,o))break}return e};function he(e){return null==e?void 0===e?h:l:$&&$ in Object(e)?function(e){var r=L.call(e,$),t=e[$];try{e[$]=void 0;var n=!0}catch(e){}var o=F.call(e);n&&(r?e[$]=t:delete e[$]);return o}(e):function(e){return F.call(e)}(e)}function ye(e){return Ne(e)&&he(e)==i}function ve(e){return!(!xe(e)||U&&U in e)&&(we(e)?z:y).test(function(e){if(null!=e){try{return k.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}function be(e){if(!xe(e))return function(e){var r=[];if(null!=e)for(var t in Object(e))r.push(t);return r}(e);var r=me(e),t=[];for(var n in e)("constructor"!=n||!r&&L.call(e,n))&&t.push(n);return t}function ge(e,r,t,n,o){e!==r&&pe(r,function(u,c){if(xe(u))o||(o=new ce),function(e,r,t,n,o,u,c){var i=S(e,t),a=S(r,t),s=c.get(a);if(s)return void ae(e,t,s);var f=u?u(i,a,t+"",e,r,c):void 0,l=void 0===f;if(l){var p=Se(a),h=!p&&Re(a),y=!p&&!h&&Pe(a);f=a,p||h||y?Se(i)?f=i:Ne(_=i)&&qe(_)?f=function(e,r){var t=-1,n=e.length;r||(r=Array(n));for(;++t<n;)r[t]=e[t];return r}(i):h?(l=!1,f=function(e,r){if(r)return e.slice();var t=e.length,n=M?M(t):new e.constructor(t);return e.copy(n),n}(a,!0)):y?(l=!1,v=a,b=!0?(new B(A=new(g=v.buffer).constructor(g.byteLength)).set(new B(g)),A):v.buffer,f=new v.constructor(b,v.byteOffset,v.length)):f=[]:function(e){if(!Ne(e)||he(e)!=d)return!1;var r=Q(e);if(null===r)return!0;var t=L.call(r,"constructor")&&r.constructor;return"function"==typeof t&&t instanceof t&&k.call(t)==D}(a)||Ie(a)?(f=i,Ie(i)?f=function(e){return function(e,r,t,n){var o=!t;t||(t={});var u=-1,c=r.length;for(;++u<c;){var i=r[u],a=n?n(t[i],e[i],i,t,e):void 0;void 0===a&&(a=e[i]),o?le(t,i,a):se(t,i,a)}return t}(e,ke(e))}(i):(!xe(i)||n&&we(i))&&(f=function(e){return"function"!=typeof e.constructor||me(e)?{}:te(Q(e))}(a))):l=!1}var v,b,g,A;var _;l&&(c.set(a,f),o(f,a,n,u,c),c.delete(a));ae(e,t,f)}(e,r,c,t,ge,n,o);else{var i=n?n(S(e,c),u,c+"",e,r,o):void 0;void 0===i&&(i=u),ae(e,c,i)}},ke)}function Ae(e,r){return Ce(function(e,r,t){return r=X(void 0===r?e.length-1:r,0),function(){for(var n=arguments,o=-1,u=X(n.length-r,0),c=Array(u);++o<u;)c[o]=n[r+o];o=-1;for(var i=Array(r+1);++o<r;)i[o]=n[o];return i[r]=t(c),function(e,r,t){switch(t.length){case 0:return e.call(r);case 1:return e.call(r,t[0]);case 2:return e.call(r,t[0],t[1]);case 3:return e.call(r,t[0],t[1],t[2])}return e.apply(r,t)}(e,this,i)}}(e,r,Fe),e+"")}function _e(e,r){var t,n,o=e.__data__;return("string"==(n=typeof(t=r))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==t:null===t)?o["string"==typeof r?"string":"hash"]:o.map}function Ee(e,r){var t=function(e,r){return null==e?void 0:e[r]}(e,r);return ve(t)?t:void 0}function je(e,r){var t=typeof e;return!!(r=null==r?c:r)&&("number"==t||"symbol"!=t&&v.test(e))&&e>-1&&e%1==0&&r>e}function me(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||x)}var Ce=function(e){var r=0,t=0;return function(){var n=Z(),c=u-(n-t);if(t=n,c>0){if(++r>=o)return arguments[0]}else r=0;return e.apply(void 0,arguments)}}(Y?function(e,r){return Y(e,"toString",{configurable:!0,enumerable:!1,value:(t=r,function(){return t}),writable:!0});var t}:Fe);function Oe(e,r){return e===r||e!=e&&r!=r}var Ie=ye(function(){return arguments}())?ye:function(e){return Ne(e)&&L.call(e,"callee")&&!G.call(e,"callee")},Se=Array.isArray;function qe(e){return null!=e&&Te(e.length)&&!we(e)}var Re=W||function(){return!1};function we(e){if(!xe(e))return!1;var r=he(e);return r==s||r==f||r==a||r==p}function Te(e){return"number"==typeof e&&e>-1&&e%1==0&&c>=e}function xe(e){var r=typeof e;return null!=e&&("object"==r||"function"==r)}function Ne(e){return null!=e&&"object"==typeof e}var Pe=I?function(e){return function(r){return e(r)}}(I):function(e){return Ne(e)&&Te(e.length)&&!!b[he(e)]};function ke(e){return qe(e)?ie(e,!0):be(e)}var Le,Ue=(Le=function(e,r,t,n){ge(e,r,t,n)},Ae(function(e,r){var t=-1,n=r.length,o=n>1?r[n-1]:void 0,u=n>2?r[2]:void 0;for(o=Le.length>3&&"function"==typeof o?(n--,o):void 0,u&&function(e,r,t){if(!xe(t))return!1;var n=typeof r;return!!("number"==n?qe(t)&&je(r,t.length):"string"==n&&r in t)&&Oe(t[r],e)}(r[0],r[1],u)&&(o=3>n?void 0:o,n=1),e=Object(e);++t<n;){var c=r[t];c&&Le(e,c,t,o)}return e}));function Fe(e){return e}e.exports=Ue}),cr=function(e,r){return ur(e.resources,r,function(e,r){return fe(e)?s({},e,r):void 0})},ir={},ar={REQUEST:function(e,r){var t,n=r.url,o=r.resourceId;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{resourceName:or(r.type).resourceName,resourceId:o,startedAt:(new Date).toISOString(),endedAt:null,hasSucceeded:!(!e.requests||!e.requests[n])&&e.requests[n].hasSucceeded,hasFailed:!(!e.requests||!e.requests[n])&&e.requests[n].hasFailed,didInvalidate:!(!e.requests||!e.requests[n])&&e.requests[n].didInvalidate,fromCache:!(!e.requests||!e.requests[n])&&e.requests[n].fromCache}),t))})},RECEIVE:function(e,r){var t,n=r.url,o=r.payload,u=r.principalResourceIds,c=or(r.type).resourceName,i=s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{endedAt:(new Date).toISOString(),hasSucceeded:!0,hasFailed:!1,didInvalidate:!1,fromCache:!1,payloadIds:Pe(c,o,u)}),t)),resources:cr(e,o)});return He(i,c,n,o,u),i},FAIL:function(e,r){var t,n=r.url;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{endedAt:(new Date).toISOString(),hasSucceeded:!1,hasFailed:!0}),t))})},RECEIVE_FROM_CACHE:function(e,r){var t,n=r.type,o=r.url,u=r.resourceId,c=r.payload,i=r.principalResourceIds,a=or(n).resourceName,f=s({},e,{requests:s({},e.requests||{},(t={},t[o]=s({},e.requests&&e.requests[o]?e.requests[o]:{},{resourceName:or(n).resourceName,resourceId:u,startedAt:(new Date).toISOString(),endedAt:(new Date).toISOString(),hasSucceeded:!0,hasFailed:!1,didInvalidate:!1,fromCache:!0,payloadIds:Pe(a,c,i)}),t)),resources:cr(e,c)});return He(f,a,o,c,i),f},INVALIDATE_RESOURCE:function(e,r){var t=r.resourceName;return s({},e,{requests:s({},Object.entries(e.requests||{}).reduce(function(e,r){var n,o=r[1];return s({},e,((n={})[r[0]]=!o.didInvalidate&&(o.resourceName===t||o.payloadIds&&o.payloadIds[t])?s({},o,{didInvalidate:!0}):o,n))},{}))})},INVALIDATE_ID:function(e,r){var t=r.resourceName,n=r.resourceId;return s({},e,{requests:s({},Object.entries(e.requests||{}).reduce(function(e,r){var o,u=r[1];return s({},e,((o={})[r[0]]=!u.didInvalidate&&(u.resourceName===t&&u.resourceId===n||u.payloadIds&&u.payloadIds[t]&&u.payloadIds[t].map(function(e){return""+e}).includes(""+n))?s({},u,{didInvalidate:!0}):u,o))},{}))})},INVALIDATE_REQUEST:function(e,r){var t,n=r.url;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{didInvalidate:!0}),t))})},RESET_RESOURCE:function(e,r){var t,n=r.resourceName,o=s({},e,{requests:s({},Object.entries(e.requests||{}).filter(function(e){var r=e[1],t=r.payloadIds;return!(n===r.resourceName||t&&Object.keys(t).includes(n))}).reduce(function(e,r){var t;return s({},e,((t={})[r[0]]=r[1],t))},{})),resources:s({},e.resources||{},(t={},t[n]=void 0,t))});return function(e,r){var t;Ve=s({},Ve,{requests:s({},Object.entries(Ve.requests).reduce(function(r,t){var n,o=t[0],u=t[1];return s({},r,Object.keys(e.requests).includes(o)?((n={})[o]=u,n):{})},{})),resources:s({},Ve.resources,(t={},t[r]=De,t))})}(o),o},RESET_ALL:function(){return Ve=s({},ze),{}}},sr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ir;return function(r){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(void 0===r)return e;if(!t.type||!t.type.startsWith("@@rest-easy"))return r;var n=ar[or(t.type).caseName];return n?n(r,t):r}}(),fr=function(){var e,r={RESET_ALL:p("@global","@reset","RESET_ALL")};return{resetAll:(e=r.RESET_ALL,function(){return{type:e}})}};e.connect=function(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];return function(e){var n=e.displayName||e.name||"Component",o=function(n){function o(r){a(this,o);var u=f(this,n.call(this,r));return u.onInjectProps=function(e,r){u.setState(function(t){var n;return t.__requestURLsByActionKey[e]!==r?{__requestURLsByActionKey:s({},t.__requestURLsByActionKey,(n={},n[e]=r,n))}:null})},u.state={__requestURLsByActionKey:{}},u.ConnectedComponent=l(u.onInjectProps).apply(void 0,t)(e),u}return function(e,r){if("function"!=typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function, not "+typeof r);e.prototype=Object.create(r&&r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),r&&(Object.setPrototypeOf?Object.setPrototypeOf(e,r):e.__proto__=r)}(o,n),o.prototype.render=function(){var e=this.ConnectedComponent,t=s({},this.props,this.state);return r.createElement(e,t)},o}(r.Component);return o.displayName="EasyConnect("+n+")",o}},e.createResource=function(e,r){return function(t){me(e,r),_e(e,t);var n=r||{},o=n.cacheLifetime,u=void 0===o?0:o,c=n.denormalizer,i=s({},h(e)),a=s({},function(e,r){return{resource:{getResource:function(t){var n=1>=arguments.length||void 0===arguments[1]||arguments[1];return nr(Q(t),e,n,r)},getResourceById:function(t,n){var o=2>=arguments.length||void 0===arguments[2]||arguments[2];return function(e,r,t,n,o){return n&&o?o([t],e.resources)[0]||null:e.resources&&e.resources[r]&&e.resources[r][t]?e.resources[r][t]:null}(Q(t),e,n,o,r)}}}}(e,c));return Object.keys(t||{}).forEach(function(r){i=s({},i,Z(e,u,t||{},r)),a=s({},a,function(e,r,t){var n;return(n={})[r]={resource:{couldPerform:function(t){return!Ke(Q(t),e,r)},isPerforming:function(t){return Ke(Q(t),e,r)},isValid:function(t){return!$e(Q(t),e,r,"didInvalidate")},hasSucceeded:function(t){return $e(Q(t),e,r,"hasSucceeded")},hasFailed:function(t){return $e(Q(t),e,r,"hasFailed")},couldPerformOnId:function(t,n){return!Ke(Q(t),e,r,n)},isPerformingOnId:function(t,n){return Ke(Q(t),e,r,n)},hasSucceededOnId:function(t,n){return $e(Q(t),e,r,"hasSucceeded",n)},hasFailedOnId:function(t,n){return $e(Q(t),e,r,"hasFailed",n)},isValidId:function(t,n){return!$e(Q(t),e,r,"didInvalidate",n)}},request:{getResource:function(n,o){var u=2>=arguments.length||void 0===arguments[2]||arguments[2];return Xe(Q(n),e,Te(e,r,o),u,t)},couldPerform:function(t,n){return!Ze(Q(t),Te(e,r,n))},isPerforming:function(t,n){return Ze(Q(t),Te(e,r,n))},isValid:function(t,n){return!er(Q(t),Te(e,r,n),"didInvalidate")},hasSucceeded:function(t,n){return er(Q(t),Te(e,r,n),"hasSucceeded")},hasFailed:function(t,n){return er(Q(t),Te(e,r,n),"hasFailed")}}},n}(e,r,c))}),{actions:i,selectors:a}}},e.reducer=sr,e.reset=function(){return(0,fr().resetAll)()},e.initializeNetwork=function(e){!function(e){K=e}(e)},Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,r){"object"==typeof exports&&"undefined"!=typeof module?r(exports,require("react"),require("react-redux")):"function"==typeof define&&define.amd?define(["exports","react","react-redux"],r):r(e.ReduxRestEasy={},e.React,e.ReactRedux)}(this,function(e,r,t){"use strict";r=r&&r.hasOwnProperty("default")?r.default:r;var n,o,u,c,i=function(e){return function(){var r=e.apply(this,arguments);return new Promise(function(e,t){return function n(o,u){try{var c=r[o](u),i=c.value}catch(e){return void t(e)}if(!c.done)return Promise.resolve(i).then(function(e){n("next",e)},function(e){n("throw",e)});e(i)}("next")})}},a=function(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")},s=Object.assign||function(e){for(var r=1;arguments.length>r;r++){var t=arguments[r];for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])}return e},f=function(e,r){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!r||"object"!=typeof r&&"function"!=typeof r?e:r},l=function(e){return function(r,n){for(var o=arguments.length,u=Array(o>2?o-2:0),c=2;o>c;c++)u[c-2]=arguments[c];return t.connect.apply(void 0,[r,n&&"function"==typeof n?function(){var r=n.apply(void 0,arguments);return Object.keys(r).reduce(function(t,n){var o;return s({},t,((o={})[n]=function(){var t=r[n].apply(r,arguments);return t&&t.__actionName&&t.__requestURL&&(e(t.__actionName,t.__requestURL),delete t.__actionName,delete t.__requestURL),t},o))},{})}:{}].concat(u))}},d=function(e,r){return function(t){return{type:e,resourceName:r,resourceId:t}}},p=function(e,r,t){return"@@rest-easy/"+e+"/"+r+"/"+t.toUpperCase()},h=function(e){var r=function(e){return{INVALIDATE_RESOURCE:p(e,"@invalidate","INVALIDATE_RESOURCE"),INVALIDATE_ID:p(e,"@invalidate","INVALIDATE_ID"),RESET_RESOURCE:p(e,"@reset","RESET_RESOURCE")}}(e),t=r.INVALIDATE_ID,n=r.RESET_RESOURCE;return{resource:{invalidate:d(r.INVALIDATE_RESOURCE,e),invalidateId:d(t,e),reset:d(n,e)}}},y=function(e){return function(r,t,n,o){return{type:e,url:r,resourceId:t,payload:n&&Object.keys(n).length?n:void 0,principalResourceIds:"string"==typeof o?[o]:o}}},v=function(e,r){var t=function(e,r){return{REQUEST:p(e,r,"REQUEST"),RECEIVE:p(e,r,"RECEIVE"),FAIL:p(e,r,"FAIL"),RECEIVE_FROM_CACHE:p(e,r,"RECEIVE_FROM_CACHE")}}(e,r),n=t.RECEIVE,o=t.FAIL,u=t.RECEIVE_FROM_CACHE;return{REQUEST:y(t.REQUEST),RECEIVE:y(n),FAIL:y(o),RECEIVE_FROM_CACHE:y(u)}},b={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},g=function(e){throw{name:"SyntaxError",message:e,at:n,text:u}},A=function(e){return e&&e!==o&&g("Expected '"+e+"' instead of '"+o+"'"),o=u.charAt(n),n+=1,o},_=function(){var e,r="";for("-"===o&&(r="-",A("-"));o>="0"&&"9">=o;)r+=o,A();if("."===o)for(r+=".";A()&&o>="0"&&"9">=o;)r+=o;if("e"===o||"E"===o)for(r+=o,A(),"-"!==o&&"+"!==o||(r+=o,A());o>="0"&&"9">=o;)r+=o,A();if(isFinite(e=+r))return e;g("Bad number")},E=function(){var e,r,t,n="";if('"'===o)for(;A();){if('"'===o)return A(),n;if("\\"===o)if(A(),"u"===o){for(t=0,r=0;4>r&&(e=parseInt(A(),16),isFinite(e));r+=1)t=16*t+e;n+=String.fromCharCode(t)}else{if("string"!=typeof b[o])break;n+=b[o]}else n+=o}g("Bad string")},j=function(){for(;o&&" ">=o;)A()};c=function(){switch(j(),o){case"{":return function(){var e,r={};if("{"===o){if(A("{"),j(),"}"===o)return A("}"),r;for(;o;){if(e=E(),j(),A(":"),Object.hasOwnProperty.call(r,e)&&g('Duplicate key "'+e+'"'),r[e]=c(),j(),"}"===o)return A("}"),r;A(","),j()}}g("Bad object")}();case"[":return function(){var e=[];if("["===o){if(A("["),j(),"]"===o)return A("]"),e;for(;o;){if(e.push(c()),j(),"]"===o)return A("]"),e;A(","),j()}}g("Bad array")}();case'"':return E();case"-":return _();default:return"0">o||o>"9"?function(){switch(o){case"t":return A("t"),A("r"),A("u"),A("e"),!0;case"f":return A("f"),A("a"),A("l"),A("s"),A("e"),!1;case"n":return A("n"),A("u"),A("l"),A("l"),null}g("Unexpected '"+o+"'")}():_()}};var m,C,O,I=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,S={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};function q(e){return I.lastIndex=0,I.test(e)?'"'+e.replace(I,function(e){var r=S[e];return"string"==typeof r?r:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+e+'"'}var R=void 0!==JSON?JSON:{parse:function(e,r){var t;return u=e,n=0,o=" ",t=c(),j(),o&&g("Syntax error"),"function"==typeof r?function e(t,n){var o,u,c=t[n];if(c&&"object"==typeof c)for(o in c)Object.prototype.hasOwnProperty.call(c,o)&&(void 0!==(u=e(c,o))?c[o]=u:delete c[o]);return r.call(t,n,c)}({"":t},""):t},stringify:function(e,r,t){var n;if(m="",C="","number"==typeof t)for(n=0;t>n;n+=1)C+=" ";else"string"==typeof t&&(C=t);if(O=r,r&&"function"!=typeof r&&("object"!=typeof r||"number"!=typeof r.length))throw Error("JSON.stringify");return function e(r,t){var n,o,u,c,i,a=m,s=t[r];switch(s&&"object"==typeof s&&"function"==typeof s.toJSON&&(s=s.toJSON(r)),"function"==typeof O&&(s=O.call(t,r,s)),typeof s){case"string":return q(s);case"number":return isFinite(s)?s+"":"null";case"boolean":case"null":return s+"";case"object":if(!s)return"null";if(m+=C,i=[],"[object Array]"===Object.prototype.toString.apply(s)){for(c=s.length,n=0;c>n;n+=1)i[n]=e(n,s)||"null";return u=0===i.length?"[]":m?"[\n"+m+i.join(",\n"+m)+"\n"+a+"]":"["+i.join(",")+"]",m=a,u}if(O&&"object"==typeof O)for(c=O.length,n=0;c>n;n+=1)"string"==typeof(o=O[n])&&(u=e(o,s))&&i.push(q(o)+(m?": ":":")+u);else for(o in s)Object.prototype.hasOwnProperty.call(s,o)&&(u=e(o,s))&&i.push(q(o)+(m?": ":":")+u);return u=0===i.length?"{}":m?"{\n"+m+i.join(",\n"+m)+"\n"+a+"}":"{"+i.join(",")+"}",m=a,u}}("",{"":e})}},w=function(e,r){r||(r={}),"function"==typeof r&&(r={cmp:r});var t=r.space||"";"number"==typeof t&&(t=Array(t+1).join(" "));var n,o="boolean"==typeof r.cycles&&r.cycles,u=r.replacer||function(e,r){return r},c=r.cmp&&(n=r.cmp,function(e){return function(r,t){return n({key:r,value:e[r]},{key:t,value:e[t]})}}),i=[];return function e(r,n,a,s){var f=t?"\n"+Array(s+1).join(t):"",l=t?": ":":";if(a&&a.toJSON&&"function"==typeof a.toJSON&&(a=a.toJSON()),void 0!==(a=u.call(r,n,a))){if("object"!=typeof a||null===a)return R.stringify(a);if(T(a)){for(var d=[],p=0;a.length>p;p++){var h=e(a,p,a[p],s+1)||R.stringify(null);d.push(f+t+h)}return"["+d.join(",")+f+"]"}if(-1!==i.indexOf(a)){if(o)return R.stringify("__cycle__");throw new TypeError("Converting circular structure to JSON")}i.push(a);var y=x(a).sort(c&&c(a));for(d=[],p=0;y.length>p;p++){var v=e(a,n=y[p],a[n],s+1);if(v){var b=R.stringify(n)+l+v;d.push(f+t+b)}}return i.splice(i.indexOf(a),1),"{"+d.join(",")+f+"}"}}({"":e},"",e,0)},T=Array.isArray||function(e){return"[object Array]"==={}.toString.call(e)},x=Object.keys||function(e){var r=Object.prototype.hasOwnProperty||function(){return!0},t=[];for(var n in e)r.call(e,n)&&t.push(n);return t},k="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function N(e,r){return e(r={exports:{}},r.exports),r.exports}var P,L=N(function(e,r){var t=Object.prototype.hasOwnProperty,n=function(){for(var e=[],r=0;256>r;++r)e.push("%"+((16>r?"0":"")+r.toString(16)).toUpperCase());return e}();r.arrayToObject=function(e,r){for(var t=r&&r.plainObjects?Object.create(null):{},n=0;e.length>n;++n)void 0!==e[n]&&(t[n]=e[n]);return t},r.merge=function(e,n,o){if(!n)return e;if("object"!=typeof n){if(Array.isArray(e))e.push(n);else{if("object"!=typeof e)return[e,n];(o.plainObjects||o.allowPrototypes||!t.call(Object.prototype,n))&&(e[n]=!0)}return e}if("object"!=typeof e)return[e].concat(n);var u=e;return Array.isArray(e)&&!Array.isArray(n)&&(u=r.arrayToObject(e,o)),Array.isArray(e)&&Array.isArray(n)?(n.forEach(function(n,u){t.call(e,u)?e[u]&&"object"==typeof e[u]?e[u]=r.merge(e[u],n,o):e.push(n):e[u]=n}),e):Object.keys(n).reduce(function(e,u){var c=n[u];return e[u]=t.call(e,u)?r.merge(e[u],c,o):c,e},u)},r.assign=function(e,r){return Object.keys(r).reduce(function(e,t){return e[t]=r[t],e},e)},r.decode=function(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(r){return e}},r.encode=function(e){if(0===e.length)return e;for(var r="string"==typeof e?e:e+"",t="",o=0;r.length>o;++o){var u=r.charCodeAt(o);45!==u&&46!==u&&95!==u&&126!==u&&(48>u||u>57)&&(65>u||u>90)&&(97>u||u>122)?128>u?t+=n[u]:2048>u?t+=n[192|u>>6]+n[128|63&u]:u>=55296&&57344>u?(u=65536+((1023&u)<<10|1023&r.charCodeAt(o+=1)),t+=n[240|u>>18]+n[128|u>>12&63]+n[128|u>>6&63]+n[128|63&u]):t+=n[224|u>>12]+n[128|u>>6&63]+n[128|63&u]:t+=r.charAt(o)}return t},r.compact=function(e){for(var r=[{obj:{o:e},prop:"o"}],t=[],n=0;r.length>n;++n)for(var o=r[n],u=o.obj[o.prop],c=Object.keys(u),i=0;c.length>i;++i){var a=c[i],s=u[a];"object"==typeof s&&null!==s&&-1===t.indexOf(s)&&(r.push({obj:u,prop:a}),t.push(s))}return function(e){for(var r;e.length;){var t=e.pop();if(Array.isArray(r=t.obj[t.prop])){for(var n=[],o=0;r.length>o;++o)void 0!==r[o]&&n.push(r[o]);t.obj[t.prop]=n}}return r}(r)},r.isRegExp=function(e){return"[object RegExp]"===Object.prototype.toString.call(e)},r.isBuffer=function(e){return null!=e&&!!(e.constructor&&e.constructor.isBuffer&&e.constructor.isBuffer(e))}}),U=String.prototype.replace,F=/%20/g,D={default:"RFC3986",formatters:{RFC1738:function(e){return U.call(e,F,"+")},RFC3986:function(e){return e}},RFC1738:"RFC1738",RFC3986:"RFC3986"},z={brackets:function(e){return e+"[]"},indices:function(e,r){return e+"["+r+"]"},repeat:function(e){return e}},V=Date.prototype.toISOString,H={delimiter:"&",encode:!0,encoder:L.encode,encodeValuesOnly:!1,serializeDate:function(e){return V.call(e)},skipNulls:!1,strictNullHandling:!1},B=function e(r,t,n,o,u,c,i,a,s,f,l,d){var p=r;if("function"==typeof i)p=i(t,p);else if(p instanceof Date)p=f(p);else if(null===p){if(o)return c&&!d?c(t,H.encoder):t;p=""}if("string"==typeof p||"number"==typeof p||"boolean"==typeof p||L.isBuffer(p))return c?[l(d?t:c(t,H.encoder))+"="+l(c(p,H.encoder))]:[l(t)+"="+l(p+"")];var h,y=[];if(void 0===p)return y;if(Array.isArray(i))h=i;else{var v=Object.keys(p);h=a?v.sort(a):v}for(var b=0;h.length>b;++b){var g=h[b];u&&null===p[g]||(y=y.concat(e(p[g],Array.isArray(p)?n(t,g):t+(s?"."+g:"["+g+"]"),n,o,u,c,i,a,s,f,l,d)))}return y},M=function(e,r){var t=e,n=r?L.assign({},r):{};if(null!=n.encoder&&"function"!=typeof n.encoder)throw new TypeError("Encoder has to be a function.");var o=void 0===n.delimiter?H.delimiter:n.delimiter,u="boolean"==typeof n.strictNullHandling?n.strictNullHandling:H.strictNullHandling,c="boolean"==typeof n.skipNulls?n.skipNulls:H.skipNulls,i="boolean"==typeof n.encode?n.encode:H.encode,a="function"==typeof n.encoder?n.encoder:H.encoder,s="function"==typeof n.sort?n.sort:null,f=void 0!==n.allowDots&&n.allowDots,l="function"==typeof n.serializeDate?n.serializeDate:H.serializeDate,d="boolean"==typeof n.encodeValuesOnly?n.encodeValuesOnly:H.encodeValuesOnly;if(void 0===n.format)n.format=D.default;else if(!Object.prototype.hasOwnProperty.call(D.formatters,n.format))throw new TypeError("Unknown format option provided.");var p,h,y=D.formatters[n.format];"function"==typeof n.filter?t=(h=n.filter)("",t):Array.isArray(n.filter)&&(p=h=n.filter);var v=[];if("object"!=typeof t||null===t)return"";var b=z[n.arrayFormat in z?n.arrayFormat:"indices"in n?n.indices?"indices":"repeat":"indices"];p||(p=Object.keys(t)),s&&p.sort(s);for(var g=0;p.length>g;++g){var A=p[g];c&&null===t[A]||(v=v.concat(B(t[A],A,b,u,c,i?a:null,h,s,f,l,y,d)))}var _=v.join(o);return _.length>0?(!0===n.addQueryPrefix?"?":"")+_:""},Q=function(e){var r,t=(r=e)&&Object.keys(r)?M(r):"";return t?"?"+t:""},J=function(e){return e&&e.restEasy?e.restEasy:(console.error('There doesn\'t seem to be a "restEasy" key in your state. In doubt, double check the docs on reducers.'),null)},G=function(e,r){return new Date-new Date(e)>1e3*r},K={getToken:function(){return"token"},requestGET:function(){return{method:"GET",headers:{Accept:"application/json",Authorization:"Bearer "+this.getToken()}}},requestPATCH:function(e){return{method:"PATCH",headers:{Accept:"application/json",Authorization:"Bearer "+this.getToken(),"Content-Type":"application/json"},body:e}},requestPUT:function(e){return{method:"PUT",headers:{Accept:"application/json",Authorization:"Bearer "+this.getToken(),"Content-Type":"application/json"},body:e}},requestPOST:function(e){return{method:"POST",headers:{Accept:"application/json",Authorization:"Bearer "+this.getToken(),"Content-Type":"application/json"},body:e}},requestDELETE:function(){return{method:"DELETE",headers:{Accept:"application/json",Authorization:"Bearer "+this.getToken()}}},handleStatusCode:function(e){if(e){if(e.status>=200&&300>e.status)return e;var r=Error(e.statusText);throw r.response=e,r}return null},handleError:(P=i(function*(e,r){try{if(e&&e.response){var t=yield e.response.json();console.error(t)}else console.error(e)}catch(e){console.error(e)}}),function(e,r){return P.apply(this,arguments)})},$=K,Y=function(){return $},W=function(e){for(var r=arguments.length,t=Array(r>1?r-1:0),n=1;r>n;n++)t[n-1]=arguments[n];if(e&&"function"==typeof e)return e.apply(void 0,t)},X=function(e,r,t,n,o,u){return function(e,c,a){return function(){var s,f=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},l=f.query,d=void 0===l?{}:l,p=f.body,h=void 0===p?{}:p,y=f.urlParams,v=void 0===y?{}:y,b=f.onSuccess,g=f.onError,A=function(e,r){var t={};for(var n in e)0>r.indexOf(n)&&Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}(f,["query","body","urlParams","onSuccess","onError"]);return s=i(function*(i,s){var f=Y(),l=f.handleError,p=f.handleStatusCode;i(r.REQUEST(c,a));try{var y=(yield W(n,v,d,h,A,i))||h,_=yield fetch(e,function(){var e=Y();return{GET:e.requestGET,PATCH:e.requestPATCH,PUT:e.requestPUT,POST:e.requestPOST,DELETE:e.requestDELETE}}()[t](y));p(_);var E=204!==_.status?yield _.json():{},j=o?o(E,J(s()).resources,v,d,y,A):{entities:E},m=j.entities;return i(r.RECEIVE(c,a,m,j.result)),yield W(u,m||{},v,d,y,A,i),W(b,m||{},A),{normalizedPayload:m||{},otherArgs:A}}catch(e){return i(r.FAIL(c,a)),l(e,i),W(g,e),{error:e}}}),function(e,r){return s.apply(this,arguments)}}}},Z=function(e,r,t,n){var o=t[n],u=o.method,c=o.url,i=o.beforeHook,a=o.normalizer,s=o.afterHook,f=v(e,n),l=X(0,f,u,i,a,s);return function(t){return function(o,i){var a=J(i()),s=t||{},d=s.urlParams,p=s.query,h=function(e){var r=("string"!=typeof e?e():e).split("/").reverse(),t=r.findIndex(function(e){return e.startsWith("::")});return-1!==t?r.length-1-t:-1}(c),y=function(e,r,t){var n="string"!=typeof e?e():e;r&&Object.keys(r).forEach(function(e){n=n.replace("::"+e,r[e]).replace(":"+e,r[e])});var o=t?Q(JSON.parse(w(t))):"";return""+n+o}(c,d,p),v=function(e,r){return(e||"")+":"+(r||"")}(n,y),b=function(e,r){if(!e||!r&&0!==r||-1===r)return null;for(var t=0,n=0;r>n;n+=1)t=e.indexOf("/",t+1);var o=e.indexOf("/",t+1);return e.substr(t+1,-1!==o?o-t-1:e.length)}(v,h),g=void 0;(function(e,r){return!(e&&r&&e.requests&&e.requests[r]&&!e.requests[r].endedAt)})(a,v)&&function(e,r,t,n){if(!("GET"===r&&e&&t&&e.requests&&e.requests[t]))return!0;var o=e.requests[t];return!o.hasSucceeded||o.didInvalidate||G(o.endedAt,n)}(a,u,v,r)&&(g=function(e,r,t,n,o){return!!("GET"===r&&e&&e.requests&&t&&null!==n)&&Object.values(e.requests).some(function(e){var r=e.endedAt,u=e.payloadIds;return e.hasSucceeded&&!e.didInvalidate&&(t===e.resourceName&&n===e.resourceId||u&&u[t]&&u[t].includes(n))&&!G(r,o)})}(a,u,e,b,r)?function(){var r,t;return o(f.RECEIVE_FROM_CACHE(v,b,((t={})[e]=((r={})[b]=null,r),t),[b]))}:function(){return o(l(y,v,b)(t))});var A=g?g():{};return A.__actionName=n,A.__requestURL=v,A}}},ee=function(e,r,t,n){var o,u=function(e){return{INVALIDATE_REQUEST:p(e,"@invalidate","INVALIDATE_REQUEST")}}(e).INVALIDATE_REQUEST;return(o={})[n]={perform:Z(e,r,t,n),invalidate:function(e,r){return function(t){return{type:e,url:t,resourceName:r}}}(u,e)},o},re="[object Object]";var te,ne,oe=Object.prototype,ue=Function.prototype.toString,ce=oe.hasOwnProperty,ie=ue.call(Object),ae=oe.toString,se=(te=Object.getPrototypeOf,ne=Object,function(e){return te(ne(e))});var fe,le=function(e){if(!function(e){return!!e&&"object"==typeof e}(e)||ae.call(e)!=re||function(e){var r=!1;if(null!=e&&"function"!=typeof e.toString)try{r=!!(e+"")}catch(e){}return r}(e))return!1;var r=se(e);if(null===r)return!0;var t=ce.call(r,"constructor")&&r.constructor;return"function"==typeof t&&t instanceof t&&ue.call(t)==ie},de=function(e){return function(r){throw Error("redux-rest-easy: "+e+" "+r)}},pe=function(e){return"string"==typeof e},he=function(e){return"function"==typeof e},ye=function(e){return void 0!==e},ve=["method","url"],be=[].concat(ve,["beforeHook","normalizer","afterHook"]),ge=["GET","POST","PATCH","PUT","DELETE"],Ae=function(e){return e+" >"},_e=function(e,r){return e+' "'+r+'" is invalid. Expected a valid function.'},Ee=function(e,r){if(r){if(!le(r)||!Object.keys(r).length)de(Ae(e)+" createResource >")("You have to provide a valid actions configuration.");Object.keys(r).forEach(function(t){var n=de(Ae(e)+" "+function(e){return e+" >"}(t)+" createResource >"),o=r[t],u=Object.keys(o);ve.forEach(function(e){u.includes(e)||n('Key "'+e+'" is missing.')}),u.forEach(function(e){be.includes(e)||n(function(e){return'Unknown key "'+e+"."}(e))});var c=o.method,i=o.url,a=o.beforeHook,s=o.normalizer,f=o.afterHook;pe(c)&&ge.includes(c)||n(function(e){return'Method "'+e+'" is invalid. Expected one of: '+ge.join(", ")+"."}(c)),i&&(pe(i)||he(i))||n(function(e){return'URL "'+e+'" is invalid. Expected a valid URL.'}(i)),ye(a)&&!he(a)&&n(_e("beforeHook",a)),ye(s)&&!he(s)&&n(_e("normalizer",s)),ye(f)&&!he(f)&&n(_e("afterHook",f))})}},je=function(e){return void 0!==e},me=["cacheLifetime","denormalizer"],Ce=function(e,r){var t,n=(t=function(e){return e+" >"}(e||"[no resource name]")+" createResource >",function(e){throw Error("redux-rest-easy: "+t+" "+e)});if(e&&"string"==typeof e||n("You have to provide a valid resource name."),r){le(r)&&Object.keys(r).length||n("You have to provide a valid resource configuration (or not at all)."),Object.keys(r).forEach(function(e){me.includes(e)||n(function(e){return'Unknown key "'+e+'" in resource config.'}(e))});var o=r.cacheLifetime,u=r.denormalizer;!je(o)||function(e){return"number"==typeof e}(o)&&o>=0||n(function(e){return'cacheLifetime "'+e+'" in resource config is invalid. Expected a number between 0 and Infinity.'}(o)),je(u)&&!function(e){return"function"==typeof e}(u)&&n(function(e,r){return e+' "'+r+'" in resource config is invalid. Expected a valid function.'}("denormalizer",u))}},Oe=N(function(e,r){function t(e,r){return e===r}function n(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t,n=null,o=null;return function(){return function(e,r,t){if(null===r||null===t||r.length!==t.length)return!1;for(var n=r.length,o=0;n>o;o++)if(!e(r[o],t[o]))return!1;return!0}(r,n,arguments)||(o=e.apply(null,arguments)),n=arguments,o}}function o(e){for(var r=arguments.length,t=Array(r>1?r-1:0),o=1;r>o;o++)t[o-1]=arguments[o];return function(){for(var r=arguments.length,o=Array(r),u=0;r>u;u++)o[u]=arguments[u];var c=0,i=o.pop(),a=function(e){var r=Array.isArray(e[0])?e[0]:e;if(!r.every(function(e){return"function"==typeof e})){var t=r.map(function(e){return typeof e}).join(", ");throw Error("Selector creators expect all input-selectors to be functions, instead received the following types: ["+t+"]")}return r}(o),s=e.apply(void 0,[function(){return c++,i.apply(null,arguments)}].concat(t)),f=n(function(){for(var e=[],r=a.length,t=0;r>t;t++)e.push(a[t].apply(null,arguments));return s.apply(null,e)});return f.resultFunc=i,f.recomputations=function(){return c},f.resetRecomputations=function(){return c=0},f}}r.__esModule=!0,r.defaultMemoize=n,r.createSelectorCreator=o,r.createStructuredSelector=function(e){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:u;if("object"!=typeof e)throw Error("createStructuredSelector expects first argument to be an object where each property is a selector, instead received a "+typeof e);var t=Object.keys(e);return r(t.map(function(r){return e[r]}),function(){for(var e=arguments.length,r=Array(e),n=0;e>n;n++)r[n]=arguments[n];return r.reduce(function(e,r,n){return e[t[n]]=r,e},{})})};var u=r.createSelector=o(n)});(fe=Oe)&&fe.__esModule&&Object.prototype.hasOwnProperty.call(fe,"default");var Ie=Oe.createSelectorCreator,Se=Oe.createSelector,qe=function(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")},Re=function(){function e(){qe(this,e),this._cache={}}return e.prototype.set=function(e,r){this._cache[e]=r},e.prototype.get=function(e){return this._cache[e]},e.prototype.remove=function(e){delete this._cache[e]},e.prototype.clear=function(){this._cache={}},e}();function we(){for(var e=arguments.length,r=Array(e),t=0;e>t;t++)r[t]=arguments[t];var n=Re;return function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=void 0,u=void 0;"function"==typeof t?(console.warn('[re-reselect] Deprecation warning: "selectorCreator" argument is discouraged and will be removed in the upcoming major release. Please use "options.selectorCreator" instead.'),o=new n,u=t):(o=t.cacheObject||new n,u=t.selectorCreator||Se);var c=function(){var t=e.apply(void 0,arguments);if("string"==typeof t||"number"==typeof t){var n=o.get(t);return void 0===n&&(n=u.apply(void 0,r),o.set(t,n)),n.apply(void 0,arguments)}};return c.getMatchingSelector=function(){var r=e.apply(void 0,arguments);return o.get(r)},c.removeMatchingSelector=function(){var r=e.apply(void 0,arguments);o.remove(r)},c.clearCache=function(){o.clear()},c.resultFunc=r[r.length-1],c}}var Te=function(e){return e.split(":")[0]},xe=function(e,r,t){return t?t.__requestURLsByActionKey?t.__requestURLsByActionKey[r]:(console.error("You seem to have forgotten to use redux-rest-easy's connect on a Component which requested "+e+"."+r),""):(console.error("You seem to have forgotten to pass ownProps to a selector related to "+e+"."+r),"")},ke={selectorCreator:Ie(function(e){var r=null;return function(){return r||(r=e.apply(void 0,arguments)),r}})},Ne=function(){return ke},Pe=function(e,r,t){return r?Object.keys(r).reduce(function(n,o){var u;return s({},n,((u={})[o]=o===e?t:Object.keys(r[o]||{}),u))},{}):{}},Le=N(function(e,r){!function(t,n){var o={version:"2.1.2",x86:{},x64:{}};function u(e,r){return(65535&e)*r+(((e>>>16)*r&65535)<<16)}function c(e,r){return e<<r|e>>>32-r}function i(e){return e=u(e^=e>>>16,2246822507),e=u(e^=e>>>13,3266489909),e^=e>>>16}function a(e,r){var t=[0,0,0,0];return t[3]+=(e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]])[3]+(r=[r[0]>>>16,65535&r[0],r[1]>>>16,65535&r[1]])[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]+r[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]+r[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]+r[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function s(e,r){var t=[0,0,0,0];return t[3]+=(e=[e[0]>>>16,65535&e[0],e[1]>>>16,65535&e[1]])[3]*(r=[r[0]>>>16,65535&r[0],r[1]>>>16,65535&r[1]])[3],t[2]+=t[3]>>>16,t[3]&=65535,t[2]+=e[2]*r[3],t[1]+=t[2]>>>16,t[2]&=65535,t[2]+=e[3]*r[2],t[1]+=t[2]>>>16,t[2]&=65535,t[1]+=e[1]*r[3],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[2]*r[2],t[0]+=t[1]>>>16,t[1]&=65535,t[1]+=e[3]*r[1],t[0]+=t[1]>>>16,t[1]&=65535,t[0]+=e[0]*r[3]+e[1]*r[2]+e[2]*r[1]+e[3]*r[0],t[0]&=65535,[t[0]<<16|t[1],t[2]<<16|t[3]]}function f(e,r){return 32===(r%=64)?[e[1],e[0]]:32>r?[e[0]<<r|e[1]>>>32-r,e[1]<<r|e[0]>>>32-r]:[e[1]<<(r-=32)|e[0]>>>32-r,e[0]<<r|e[1]>>>32-r]}function l(e,r){return 0===(r%=64)?e:32>r?[e[0]<<r|e[1]>>>32-r,e[1]<<r]:[e[1]<<r-32,0]}function d(e,r){return[e[0]^r[0],e[1]^r[1]]}function p(e){return e=d(e=s(e=d(e=s(e=d(e,[0,e[0]>>>1]),[4283543511,3981806797]),[0,e[0]>>>1]),[3301882366,444984403]),[0,e[0]>>>1])}o.x86.hash32=function(e,r){for(var t=(e=e||"").length%4,n=e.length-t,o=r=r||0,a=0,s=3432918353,f=461845907,l=0;n>l;l+=4)o=u(o=c(o^=a=u(a=c(a=u(a=255&e.charCodeAt(l)|(255&e.charCodeAt(l+1))<<8|(255&e.charCodeAt(l+2))<<16|(255&e.charCodeAt(l+3))<<24,s),15),f),13),5)+3864292196;switch(a=0,t){case 3:a^=(255&e.charCodeAt(l+2))<<16;case 2:a^=(255&e.charCodeAt(l+1))<<8;case 1:o^=a=u(a=c(a=u(a^=255&e.charCodeAt(l),s),15),f)}return(o=i(o^=e.length))>>>0},o.x86.hash128=function(e,r){for(var t=(e=e||"").length%16,n=e.length-t,o=r=r||0,a=r,s=r,f=r,l=0,d=0,p=0,h=0,y=597399067,v=2869860233,b=951274213,g=2716044179,A=0;n>A;A+=16)l=255&e.charCodeAt(A)|(255&e.charCodeAt(A+1))<<8|(255&e.charCodeAt(A+2))<<16|(255&e.charCodeAt(A+3))<<24,d=255&e.charCodeAt(A+4)|(255&e.charCodeAt(A+5))<<8|(255&e.charCodeAt(A+6))<<16|(255&e.charCodeAt(A+7))<<24,p=255&e.charCodeAt(A+8)|(255&e.charCodeAt(A+9))<<8|(255&e.charCodeAt(A+10))<<16|(255&e.charCodeAt(A+11))<<24,h=255&e.charCodeAt(A+12)|(255&e.charCodeAt(A+13))<<8|(255&e.charCodeAt(A+14))<<16|(255&e.charCodeAt(A+15))<<24,o=c(o^=l=u(l=c(l=u(l,y),15),v),19),o=u(o+=a,5)+1444728091,a=c(a^=d=u(d=c(d=u(d,v),16),b),17),a=u(a+=s,5)+197830471,s=c(s^=p=u(p=c(p=u(p,b),17),g),15),s=u(s+=f,5)+2530024501,f=c(f^=h=u(h=c(h=u(h,g),18),y),13),f=u(f+=o,5)+850148119;switch(l=0,d=0,p=0,h=0,t){case 15:h^=e.charCodeAt(A+14)<<16;case 14:h^=e.charCodeAt(A+13)<<8;case 13:f^=h=u(h=c(h=u(h^=e.charCodeAt(A+12),g),18),y);case 12:p^=e.charCodeAt(A+11)<<24;case 11:p^=e.charCodeAt(A+10)<<16;case 10:p^=e.charCodeAt(A+9)<<8;case 9:s^=p=u(p=c(p=u(p^=e.charCodeAt(A+8),b),17),g);case 8:d^=e.charCodeAt(A+7)<<24;case 7:d^=e.charCodeAt(A+6)<<16;case 6:d^=e.charCodeAt(A+5)<<8;case 5:a^=d=u(d=c(d=u(d^=e.charCodeAt(A+4),v),16),b);case 4:l^=e.charCodeAt(A+3)<<24;case 3:l^=e.charCodeAt(A+2)<<16;case 2:l^=e.charCodeAt(A+1)<<8;case 1:o^=l=u(l=c(l=u(l^=e.charCodeAt(A),y),15),v)}return o^=e.length,o+=a^=e.length,o+=s^=e.length,a+=o+=f^=e.length,s+=o,f+=o,o=i(o),o+=a=i(a),o+=s=i(s),a+=o+=f=i(f),s+=o,f+=o,("00000000"+(o>>>0).toString(16)).slice(-8)+("00000000"+(a>>>0).toString(16)).slice(-8)+("00000000"+(s>>>0).toString(16)).slice(-8)+("00000000"+(f>>>0).toString(16)).slice(-8)},o.x64.hash128=function(e,r){for(var t=(e=e||"").length%16,n=e.length-t,o=[0,r=r||0],u=[0,r],c=[0,0],i=[0,0],h=[2277735313,289559509],y=[1291169091,658871167],v=0;n>v;v+=16)c=[255&e.charCodeAt(v+4)|(255&e.charCodeAt(v+5))<<8|(255&e.charCodeAt(v+6))<<16|(255&e.charCodeAt(v+7))<<24,255&e.charCodeAt(v)|(255&e.charCodeAt(v+1))<<8|(255&e.charCodeAt(v+2))<<16|(255&e.charCodeAt(v+3))<<24],i=[255&e.charCodeAt(v+12)|(255&e.charCodeAt(v+13))<<8|(255&e.charCodeAt(v+14))<<16|(255&e.charCodeAt(v+15))<<24,255&e.charCodeAt(v+8)|(255&e.charCodeAt(v+9))<<8|(255&e.charCodeAt(v+10))<<16|(255&e.charCodeAt(v+11))<<24],o=a(s(o=a(o=f(o=d(o,c=s(c=f(c=s(c,h),31),y)),27),u),[0,5]),[0,1390208809]),u=a(s(u=a(u=f(u=d(u,i=s(i=f(i=s(i,y),33),h)),31),o),[0,5]),[0,944331445]);switch(c=[0,0],i=[0,0],t){case 15:i=d(i,l([0,e.charCodeAt(v+14)],48));case 14:i=d(i,l([0,e.charCodeAt(v+13)],40));case 13:i=d(i,l([0,e.charCodeAt(v+12)],32));case 12:i=d(i,l([0,e.charCodeAt(v+11)],24));case 11:i=d(i,l([0,e.charCodeAt(v+10)],16));case 10:i=d(i,l([0,e.charCodeAt(v+9)],8));case 9:u=d(u,i=s(i=f(i=s(i=d(i,[0,e.charCodeAt(v+8)]),y),33),h));case 8:c=d(c,l([0,e.charCodeAt(v+7)],56));case 7:c=d(c,l([0,e.charCodeAt(v+6)],48));case 6:c=d(c,l([0,e.charCodeAt(v+5)],40));case 5:c=d(c,l([0,e.charCodeAt(v+4)],32));case 4:c=d(c,l([0,e.charCodeAt(v+3)],24));case 3:c=d(c,l([0,e.charCodeAt(v+2)],16));case 2:c=d(c,l([0,e.charCodeAt(v+1)],8));case 1:o=d(o,c=s(c=f(c=s(c=d(c,[0,e.charCodeAt(v)]),h),31),y))}return o=d(o,[0,e.length]),u=a(u=d(u,[0,e.length]),o=a(o,u)),o=p(o),u=a(u=p(u),o=a(o,u)),("00000000"+(o[0]>>>0).toString(16)).slice(-8)+("00000000"+(o[1]>>>0).toString(16)).slice(-8)+("00000000"+(u[0]>>>0).toString(16)).slice(-8)+("00000000"+(u[1]>>>0).toString(16)).slice(-8)},e.exports&&(r=e.exports=o),r.murmurHash3=o}()}),Ue=Le,Fe=N(function(e){e.exports={v3:Ue},function(){throw Error("Dynamic requires are not currently supported by rollup-plugin-commonjs")}.main===e&&console.log(e.exports.v3)}).v3,De=function(e){return Fe.x64.hash128(w(e||null))},ze=De([]),Ve={empty:ze,requests:{},resources:{}},He=s({},Ve),Be=function(e,r,t,n,o){var u,c,i=Pe(r,n,o),a=Object.keys(i).reduce(function(r,n){var o;return s({},r,((o={})[n]=e&&e.requests&&e.requests[t]&&e.requests[t].payloadIds&&e.requests[t].payloadIds[n]?De(e.requests[t].payloadIds[n]):ze,o))},{});He=s({},He,{requests:s({},He.requests,(u={},u[t]=a,u)),resources:s({},He.resources,(c={_getResourcesHash:function(){return De(e.resources)}},c[r]=e.resources&&e.resources[r]?De(e.resources[r]):ze,c))})},Me=function(){return He.empty},Qe=function(e,r){return He.requests[e]?He.requests[e][r]:ze},Je=function(e){return He.resources[e]?He.resources[e]:ze},Ge=[],Ke=function(e,r){return("number"==typeof e?""+e:e)===("number"==typeof r?""+r:r)},$e=function(e,r,t){var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:-1;return!!e.requests&&Object.entries(e.requests).some(function(e){var o=e[1],u=o.resourceName,c=o.resourceId,i=o.endedAt;return Te(e[0])===t&&u===r&&(-1===n||null!==c&&Ke(c,n))&&!i})},Ye=function(e,r,t,n){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1,u=e.requests&&Object.entries(e.requests).filter(function(e){var n=e[1],u=n.resourceName,c=n.resourceId,i=n.endedAt,a=n.payloadIds;return Te(e[0])===t&&u===r&&(-1===o||null!==c&&Ke(c,o)||!!i&&a&&a[r]&&a[r].includes(o))}).map(function(e){return e[1]});return!(!u||!u.length)&&u.reduce(function(e,r){return r.endedAt&&e.endedAt&&r.endedAt>e.endedAt?r:e},u[0])[n]},We=function(e,r){return e.resources&&e.resources[r]?e.resources[r]:null},Xe=function(e,r,t){return e.requests&&e.requests[t]&&e.requests[t].payloadIds&&e.requests[t].payloadIds[r]?e.requests[t].payloadIds[r]:null},Ze=we(function(e){return e.resources},We,Xe,function(e,r,t,n){return n},function(e,r,t,n,o){return o},function(e,r,t,n,o){return r&&t?n&&o?o(t,e):t.reduce(function(e,t){return[].concat(e,[r[t]])},[]):Ge})(function(e,r,t,n,o){var u=We(e,r),c=Xe(e,r,t);return u&&c?n&&o?n+"-"+Object.keys(e.requests[t].payloadIds).map(function(e){return Qe(t,e)+"-"+Je(e)}).join("--"):n+"-"+Qe(t,r)+"-"+Je(r):Me()},Ne()),er=function(e,r){return!(!e.requests||!e.requests[r]||e.requests[r].endedAt)},rr=function(e,r,t){return!!(e.requests&&e.requests[r]&&e.requests[r][t])},tr=[],nr=function(e,r){return e.resources&&e.resources[r]?e.resources[r]:null},or=we(function(e){return e.resources},nr,function(e,r,t){return t},function(e,r,t,n){return n},function(e,r,t,n){return r?t&&n?n(Object.keys(r),e):Object.values(r):tr})(function(e,r,t,n){return nr(e,r)?t&&n?t+"-"+(He.resources._getResourcesHash?He.resources._getResourcesHash():ze):t+"-"+Je(r):Me()},Ne()),ur=function(e){var r=e.split("/");return{resourceName:r[1],actionName:r[2],caseName:r[3]}},cr=N(function(e,r){var t=200,n="__lodash_hash_undefined__",o=800,u=16,c=9007199254740991,i="[object Arguments]",a="[object AsyncFunction]",s="[object Function]",f="[object GeneratorFunction]",l="[object Null]",d="[object Object]",p="[object Proxy]",h="[object Undefined]",y=/^\[object .+?Constructor\]$/,v=/^(?:0|[1-9]\d*)$/,b={};b["[object Float32Array]"]=b["[object Float64Array]"]=b["[object Int8Array]"]=b["[object Int16Array]"]=b["[object Int32Array]"]=b["[object Uint8Array]"]=b["[object Uint8ClampedArray]"]=b["[object Uint16Array]"]=b["[object Uint32Array]"]=!0,b[i]=b["[object Array]"]=b["[object ArrayBuffer]"]=b["[object Boolean]"]=b["[object DataView]"]=b["[object Date]"]=b["[object Error]"]=b[s]=b["[object Map]"]=b["[object Number]"]=b[d]=b["[object RegExp]"]=b["[object Set]"]=b["[object String]"]=b["[object WeakMap]"]=!1;var g="object"==typeof k&&k&&k.Object===Object&&k,A="object"==typeof self&&self&&self.Object===Object&&self,_=g||A||Function("return this")(),E=r&&!r.nodeType&&r,j=E&&e&&!e.nodeType&&e,m=j&&j.exports===E,C=m&&g.process,O=function(){try{return C&&C.binding&&C.binding("util")}catch(e){}}(),I=O&&O.isTypedArray;function S(e,r){return"__proto__"==r?void 0:e[r]}var q,R,w,T=Array.prototype,x=Object.prototype,N=_["__core-js_shared__"],P=Function.prototype.toString,L=x.hasOwnProperty,U=(q=/[^.]+$/.exec(N&&N.keys&&N.keys.IE_PROTO||""))?"Symbol(src)_1."+q:"",F=x.toString,D=P.call(Object),z=RegExp("^"+P.call(L).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),V=m?_.Buffer:void 0,H=_.Symbol,B=_.Uint8Array,M=V?V.allocUnsafe:void 0,Q=(R=Object.getPrototypeOf,w=Object,function(e){return R(w(e))}),J=Object.create,G=x.propertyIsEnumerable,K=T.splice,$=H?H.toStringTag:void 0,Y=function(){try{var e=Ee(Object,"defineProperty");return e({},"",{}),e}catch(e){}}(),W=V?V.isBuffer:void 0,X=Math.max,Z=Date.now,ee=Ee(_,"Map"),re=Ee(Object,"create"),te=function(){function e(){}return function(r){if(!xe(r))return{};if(J)return J(r);e.prototype=r;var t=new e;return e.prototype=void 0,t}}();function ne(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function oe(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function ue(e){var r=-1,t=null==e?0:e.length;for(this.clear();++r<t;){var n=e[r];this.set(n[0],n[1])}}function ce(e){var r=this.__data__=new oe(e);this.size=r.size}function ie(e,r){var t=Se(e),n=!t&&Ie(e),o=!t&&!n&&Re(e),u=!t&&!n&&!o&&Ne(e),c=t||n||o||u,i=c?function(e,r){for(var t=-1,n=Array(e);++t<e;)n[t]=r(t);return n}(e.length,String):[],a=i.length;for(var s in e)!r&&!L.call(e,s)||c&&("length"==s||o&&("offset"==s||"parent"==s)||u&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||je(s,a))||i.push(s);return i}function ae(e,r,t){(void 0===t||Oe(e[r],t))&&(void 0!==t||r in e)||le(e,r,t)}function se(e,r,t){var n=e[r];L.call(e,r)&&Oe(n,t)&&(void 0!==t||r in e)||le(e,r,t)}function fe(e,r){for(var t=e.length;t--;)if(Oe(e[t][0],r))return t;return-1}function le(e,r,t){"__proto__"==r&&Y?Y(e,r,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[r]=t}ne.prototype.clear=function(){this.__data__=re?re(null):{},this.size=0},ne.prototype.delete=function(e){var r=this.has(e)&&delete this.__data__[e];return this.size-=r?1:0,r},ne.prototype.get=function(e){var r=this.__data__;if(re){var t=r[e];return t===n?void 0:t}return L.call(r,e)?r[e]:void 0},ne.prototype.has=function(e){var r=this.__data__;return re?void 0!==r[e]:L.call(r,e)},ne.prototype.set=function(e,r){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=re&&void 0===r?n:r,this},oe.prototype.clear=function(){this.__data__=[],this.size=0},oe.prototype.delete=function(e){var r=this.__data__,t=fe(r,e);return t>=0&&(t==r.length-1?r.pop():K.call(r,t,1),--this.size,!0)},oe.prototype.get=function(e){var r=this.__data__,t=fe(r,e);return 0>t?void 0:r[t][1]},oe.prototype.has=function(e){return fe(this.__data__,e)>-1},oe.prototype.set=function(e,r){var t=this.__data__,n=fe(t,e);return 0>n?(++this.size,t.push([e,r])):t[n][1]=r,this},ue.prototype.clear=function(){this.size=0,this.__data__={hash:new ne,map:new(ee||oe),string:new ne}},ue.prototype.delete=function(e){var r=_e(this,e).delete(e);return this.size-=r?1:0,r},ue.prototype.get=function(e){return _e(this,e).get(e)},ue.prototype.has=function(e){return _e(this,e).has(e)},ue.prototype.set=function(e,r){var t=_e(this,e),n=t.size;return t.set(e,r),this.size+=t.size==n?0:1,this},ce.prototype.clear=function(){this.__data__=new oe,this.size=0},ce.prototype.delete=function(e){var r=this.__data__,t=r.delete(e);return this.size=r.size,t},ce.prototype.get=function(e){return this.__data__.get(e)},ce.prototype.has=function(e){return this.__data__.has(e)},ce.prototype.set=function(e,r){var n=this.__data__;if(n instanceof oe){var o=n.__data__;if(!ee||t-1>o.length)return o.push([e,r]),this.size=++n.size,this;n=this.__data__=new ue(o)}return n.set(e,r),this.size=n.size,this};var de,pe=function(e,r,t){for(var n=-1,o=Object(e),u=t(e),c=u.length;c--;){var i=u[de?c:++n];if(!1===r(o[i],i,o))break}return e};function he(e){return null==e?void 0===e?h:l:$&&$ in Object(e)?function(e){var r=L.call(e,$),t=e[$];try{e[$]=void 0;var n=!0}catch(e){}var o=F.call(e);n&&(r?e[$]=t:delete e[$]);return o}(e):function(e){return F.call(e)}(e)}function ye(e){return ke(e)&&he(e)==i}function ve(e){return!(!xe(e)||U&&U in e)&&(we(e)?z:y).test(function(e){if(null!=e){try{return P.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(e))}function be(e){if(!xe(e))return function(e){var r=[];if(null!=e)for(var t in Object(e))r.push(t);return r}(e);var r=me(e),t=[];for(var n in e)("constructor"!=n||!r&&L.call(e,n))&&t.push(n);return t}function ge(e,r,t,n,o){e!==r&&pe(r,function(u,c){if(xe(u))o||(o=new ce),function(e,r,t,n,o,u,c){var i=S(e,t),a=S(r,t),s=c.get(a);if(s)return void ae(e,t,s);var f=u?u(i,a,t+"",e,r,c):void 0,l=void 0===f;if(l){var p=Se(a),h=!p&&Re(a),y=!p&&!h&&Ne(a);f=a,p||h||y?Se(i)?f=i:ke(_=i)&&qe(_)?f=function(e,r){var t=-1,n=e.length;r||(r=Array(n));for(;++t<n;)r[t]=e[t];return r}(i):h?(l=!1,f=function(e,r){if(r)return e.slice();var t=e.length,n=M?M(t):new e.constructor(t);return e.copy(n),n}(a,!0)):y?(l=!1,v=a,b=!0?(new B(A=new(g=v.buffer).constructor(g.byteLength)).set(new B(g)),A):v.buffer,f=new v.constructor(b,v.byteOffset,v.length)):f=[]:function(e){if(!ke(e)||he(e)!=d)return!1;var r=Q(e);if(null===r)return!0;var t=L.call(r,"constructor")&&r.constructor;return"function"==typeof t&&t instanceof t&&P.call(t)==D}(a)||Ie(a)?(f=i,Ie(i)?f=function(e){return function(e,r,t,n){var o=!t;t||(t={});var u=-1,c=r.length;for(;++u<c;){var i=r[u],a=n?n(t[i],e[i],i,t,e):void 0;void 0===a&&(a=e[i]),o?le(t,i,a):se(t,i,a)}return t}(e,Pe(e))}(i):(!xe(i)||n&&we(i))&&(f=function(e){return"function"!=typeof e.constructor||me(e)?{}:te(Q(e))}(a))):l=!1}var v,b,g,A;var _;l&&(c.set(a,f),o(f,a,n,u,c),c.delete(a));ae(e,t,f)}(e,r,c,t,ge,n,o);else{var i=n?n(S(e,c),u,c+"",e,r,o):void 0;void 0===i&&(i=u),ae(e,c,i)}},Pe)}function Ae(e,r){return Ce(function(e,r,t){return r=X(void 0===r?e.length-1:r,0),function(){for(var n=arguments,o=-1,u=X(n.length-r,0),c=Array(u);++o<u;)c[o]=n[r+o];o=-1;for(var i=Array(r+1);++o<r;)i[o]=n[o];return i[r]=t(c),function(e,r,t){switch(t.length){case 0:return e.call(r);case 1:return e.call(r,t[0]);case 2:return e.call(r,t[0],t[1]);case 3:return e.call(r,t[0],t[1],t[2])}return e.apply(r,t)}(e,this,i)}}(e,r,Fe),e+"")}function _e(e,r){var t,n,o=e.__data__;return("string"==(n=typeof(t=r))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==t:null===t)?o["string"==typeof r?"string":"hash"]:o.map}function Ee(e,r){var t=function(e,r){return null==e?void 0:e[r]}(e,r);return ve(t)?t:void 0}function je(e,r){var t=typeof e;return!!(r=null==r?c:r)&&("number"==t||"symbol"!=t&&v.test(e))&&e>-1&&e%1==0&&r>e}function me(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||x)}var Ce=function(e){var r=0,t=0;return function(){var n=Z(),c=u-(n-t);if(t=n,c>0){if(++r>=o)return arguments[0]}else r=0;return e.apply(void 0,arguments)}}(Y?function(e,r){return Y(e,"toString",{configurable:!0,enumerable:!1,value:(t=r,function(){return t}),writable:!0});var t}:Fe);function Oe(e,r){return e===r||e!=e&&r!=r}var Ie=ye(function(){return arguments}())?ye:function(e){return ke(e)&&L.call(e,"callee")&&!G.call(e,"callee")},Se=Array.isArray;function qe(e){return null!=e&&Te(e.length)&&!we(e)}var Re=W||function(){return!1};function we(e){if(!xe(e))return!1;var r=he(e);return r==s||r==f||r==a||r==p}function Te(e){return"number"==typeof e&&e>-1&&e%1==0&&c>=e}function xe(e){var r=typeof e;return null!=e&&("object"==r||"function"==r)}function ke(e){return null!=e&&"object"==typeof e}var Ne=I?function(e){return function(r){return e(r)}}(I):function(e){return ke(e)&&Te(e.length)&&!!b[he(e)]};function Pe(e){return qe(e)?ie(e,!0):be(e)}var Le,Ue=(Le=function(e,r,t,n){ge(e,r,t,n)},Ae(function(e,r){var t=-1,n=r.length,o=n>1?r[n-1]:void 0,u=n>2?r[2]:void 0;for(o=Le.length>3&&"function"==typeof o?(n--,o):void 0,u&&function(e,r,t){if(!xe(t))return!1;var n=typeof r;return!!("number"==n?qe(t)&&je(r,t.length):"string"==n&&r in t)&&Oe(t[r],e)}(r[0],r[1],u)&&(o=3>n?void 0:o,n=1),e=Object(e);++t<n;){var c=r[t];c&&Le(e,c,t,o)}return e}));function Fe(e){return e}e.exports=Ue}),ir=function(e,r){return cr(e.resources,r,function(e,r){return le(e)?s({},e,r):void 0})},ar={},sr={REQUEST:function(e,r){var t,n=r.url,o=r.resourceId;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{resourceName:ur(r.type).resourceName,resourceId:o,startedAt:(new Date).toISOString(),endedAt:null,hasSucceeded:!(!e.requests||!e.requests[n])&&e.requests[n].hasSucceeded,hasFailed:!(!e.requests||!e.requests[n])&&e.requests[n].hasFailed,didInvalidate:!(!e.requests||!e.requests[n])&&e.requests[n].didInvalidate,fromCache:!(!e.requests||!e.requests[n])&&e.requests[n].fromCache}),t))})},RECEIVE:function(e,r){var t,n=r.url,o=r.payload,u=r.principalResourceIds,c=ur(r.type).resourceName,i=s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{endedAt:(new Date).toISOString(),hasSucceeded:!0,hasFailed:!1,didInvalidate:!1,fromCache:!1,payloadIds:Pe(c,o,u)}),t)),resources:ir(e,o)});return Be(i,c,n,o,u),i},FAIL:function(e,r){var t,n=r.url;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{endedAt:(new Date).toISOString(),hasSucceeded:!1,hasFailed:!0}),t))})},RECEIVE_FROM_CACHE:function(e,r){var t,n=r.type,o=r.url,u=r.resourceId,c=r.payload,i=r.principalResourceIds,a=ur(n).resourceName,f=s({},e,{requests:s({},e.requests||{},(t={},t[o]=s({},e.requests&&e.requests[o]?e.requests[o]:{},{resourceName:ur(n).resourceName,resourceId:u,startedAt:(new Date).toISOString(),endedAt:(new Date).toISOString(),hasSucceeded:!0,hasFailed:!1,didInvalidate:!1,fromCache:!0,payloadIds:Pe(a,c,i)}),t)),resources:ir(e,c)});return Be(f,a,o,c,i),f},INVALIDATE_RESOURCE:function(e,r){var t=r.resourceName;return s({},e,{requests:s({},Object.entries(e.requests||{}).reduce(function(e,r){var n,o=r[1];return s({},e,((n={})[r[0]]=!o.didInvalidate&&(o.resourceName===t||o.payloadIds&&o.payloadIds[t])?s({},o,{didInvalidate:!0}):o,n))},{}))})},INVALIDATE_ID:function(e,r){var t=r.resourceName,n=r.resourceId;return s({},e,{requests:s({},Object.entries(e.requests||{}).reduce(function(e,r){var o,u=r[1];return s({},e,((o={})[r[0]]=!u.didInvalidate&&(u.resourceName===t&&u.resourceId===n||u.payloadIds&&u.payloadIds[t]&&u.payloadIds[t].map(function(e){return""+e}).includes(""+n))?s({},u,{didInvalidate:!0}):u,o))},{}))})},INVALIDATE_REQUEST:function(e,r){var t,n=r.url;return s({},e,{requests:s({},e.requests||{},(t={},t[n]=s({},e.requests&&e.requests[n]?e.requests[n]:{},{didInvalidate:!0}),t))})},RESET_RESOURCE:function(e,r){var t,n=r.resourceName,o=s({},e,{requests:s({},Object.entries(e.requests||{}).filter(function(e){var r=e[1],t=r.payloadIds;return!(n===r.resourceName||t&&Object.keys(t).includes(n))}).reduce(function(e,r){var t;return s({},e,((t={})[r[0]]=r[1],t))},{})),resources:s({},e.resources||{},(t={},t[n]=void 0,t))});return function(e,r){var t;He=s({},He,{requests:s({},Object.entries(He.requests).reduce(function(r,t){var n,o=t[0],u=t[1];return s({},r,Object.keys(e.requests).includes(o)?((n={})[o]=u,n):{})},{})),resources:s({},He.resources,(t={},t[r]=ze,t))})}(o),o},RESET_ALL:function(){return He=s({},Ve),{}}},fr=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:ar;return function(r){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(void 0===r)return e;if(!t.type||!t.type.startsWith("@@rest-easy"))return r;var n=sr[ur(t.type).caseName];return n?n(r,t):r}}(),lr=function(){var e,r={RESET_ALL:p("@global","@reset","RESET_ALL")};return{resetAll:(e=r.RESET_ALL,function(){return{type:e}})}};e.connect=function(){for(var e=arguments.length,t=Array(e),n=0;e>n;n++)t[n]=arguments[n];return function(e){var n=e.displayName||e.name||"Component",o=function(n){function o(r){a(this,o);var u=f(this,n.call(this,r));return u.onInjectProps=function(e,r){u.setState(function(t){var n;return t.__requestURLsByActionKey[e]!==r?{__requestURLsByActionKey:s({},t.__requestURLsByActionKey,(n={},n[e]=r,n))}:null})},u.state={__requestURLsByActionKey:{}},u.ConnectedComponent=l(u.onInjectProps).apply(void 0,t)(e),u}return function(e,r){if("function"!=typeof r&&null!==r)throw new TypeError("Super expression must either be null or a function, not "+typeof r);e.prototype=Object.create(r&&r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),r&&(Object.setPrototypeOf?Object.setPrototypeOf(e,r):e.__proto__=r)}(o,n),o.prototype.render=function(){var e=this.ConnectedComponent,t=s({},this.props,this.state);return r.createElement(e,t)},o}(r.Component);return o.displayName="EasyConnect("+n+")",o}},e.createResource=function(e,r){return function(t){Ce(e,r),Ee(e,t);var n=r||{},o=n.cacheLifetime,u=void 0===o?0:o,c=n.denormalizer,i=s({},h(e)),a=s({},function(e,r){return{resource:{getResource:function(t){var n=1>=arguments.length||void 0===arguments[1]||arguments[1];return or(J(t),e,n,r)},getResourceById:function(t,n){var o=2>=arguments.length||void 0===arguments[2]||arguments[2];return function(e,r,t,n,o){return n&&o?o([t],e.resources)[0]||null:e.resources&&e.resources[r]&&e.resources[r][t]?e.resources[r][t]:null}(J(t),e,n,o,r)}}}}(e,c));return Object.keys(t||{}).forEach(function(r){i=s({},i,ee(e,u,t||{},r)),a=s({},a,function(e,r,t){var n;return(n={})[r]={resource:{couldPerform:function(t){return!$e(J(t),e,r)},isPerforming:function(t){return $e(J(t),e,r)},isValid:function(t){return!Ye(J(t),e,r,"didInvalidate")},hasSucceeded:function(t){return Ye(J(t),e,r,"hasSucceeded")},hasFailed:function(t){return Ye(J(t),e,r,"hasFailed")},couldPerformOnId:function(t,n){return!$e(J(t),e,r,n)},isPerformingOnId:function(t,n){return $e(J(t),e,r,n)},hasSucceededOnId:function(t,n){return Ye(J(t),e,r,"hasSucceeded",n)},hasFailedOnId:function(t,n){return Ye(J(t),e,r,"hasFailed",n)},isValidId:function(t,n){return!Ye(J(t),e,r,"didInvalidate",n)}},request:{getResource:function(n,o){var u=2>=arguments.length||void 0===arguments[2]||arguments[2];return Ze(J(n),e,xe(e,r,o),u,t)},couldPerform:function(t,n){return!er(J(t),xe(e,r,n))},isPerforming:function(t,n){return er(J(t),xe(e,r,n))},isValid:function(t,n){return!rr(J(t),xe(e,r,n),"didInvalidate")},hasSucceeded:function(t,n){return rr(J(t),xe(e,r,n),"hasSucceeded")},hasFailed:function(t,n){return rr(J(t),xe(e,r,n),"hasFailed")}}},n}(e,r,c))}),{actions:i,selectors:a}}},e.reducer=fr,e.reset=function(){return(0,lr().resetAll)()},e.initializeNetworkHelpers=function(e){!function(e){$=e?s({},K,e):K}(e)},Object.defineProperty(e,"__esModule",{value:!0})});

@@ -9,4 +9,6 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };

/* eslint-disable import/no-unresolved, import/extensions */
import React from 'react';
import { connect } from 'react-redux';
/* eslint-enable import/no-unresolved, import/extensions */

@@ -13,0 +15,0 @@ /* eslint-disable no-underscore-dangle */

@@ -5,2 +5,2 @@ export { default as connect } from './connect';

export { default as reset } from './reset';
export { default as initializeNetwork } from './initializeNetwork';
export { default as initializeNetworkHelpers } from './initializeNetworkHelpers';
function _asyncToGenerator(fn) { return function () { var gen = fn.apply(this, arguments); return new Promise(function (resolve, reject) { function step(key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { return Promise.resolve(value).then(function (value) { step("next", value); }, function (err) { step("throw", err); }); } } return step("next"); }); }; }
// TODO: manage token so that defaults can be used as-is. Right now they are just an example.
var DEFAULT_NETWORK_HELPERS = {
getToken: function getToken() {
return 'token';
},
requestGET: function requestGET() {

@@ -9,3 +11,4 @@ return {

headers: {
Accept: 'application/json'
Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken()
}

@@ -19,2 +22,3 @@ };

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -30,2 +34,3 @@ },

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -41,2 +46,3 @@ },

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -51,6 +57,8 @@ },

headers: {
Accept: 'application/json'
Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken()
}
};
},
handleStatusCode: function handleStatusCode(response) {

@@ -69,30 +77,27 @@ if (response) {

},
handleError: function handleError() {
return function () {
var _ref = _asyncToGenerator(function* (err, dispatch) {
try {
if (err && err.response) {
var error = yield err.response.json();
// eslint-disable-next-line no-unused-vars
handleError: function () {
var _ref = _asyncToGenerator(function* (err, dispatch) {
try {
if (err && err.response) {
var error = yield err.response.json();
if (dispatch) {
// dispatch some action to warn the user about the error
} else {
// eslint-disable-next-line no-alert
alert(error.message);
}
} else {
// eslint-disable-next-line no-console
console.error(err);
}
} catch (e) {
// dispatch some action to warn the user about the error
// eslint-disable-next-line no-console
console.error(e);
console.error(error);
} else {
// eslint-disable-next-line no-console
console.error(err);
}
});
} catch (e) {
// eslint-disable-next-line no-console
console.error(e);
}
});
return function (_x, _x2) {
return _ref.apply(this, arguments);
};
}();
}
return function handleError(_x, _x2) {
return _ref.apply(this, arguments);
};
}()
};

@@ -99,0 +104,0 @@

@@ -1,11 +0,15 @@

import defaultNetworkHelpers from './getDefaultNetworkHelpers';
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
var networkHelpers = void 0;
import getDefaultNetworkHelpers from './getDefaultNetworkHelpers';
var DEFAULT_NETWORK_HELPERS = getDefaultNetworkHelpers();
var networkHelpers = DEFAULT_NETWORK_HELPERS;
export var setNetworkHelpers = function setNetworkHelpers(helpers) {
networkHelpers = helpers;
networkHelpers = helpers ? _extends({}, DEFAULT_NETWORK_HELPERS, helpers) : DEFAULT_NETWORK_HELPERS;
};
export var getNetworkHelpers = function getNetworkHelpers() {
return networkHelpers || defaultNetworkHelpers();
return networkHelpers;
};

@@ -5,4 +5,5 @@ 'use strict';

var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; /* eslint-disable import/no-unresolved, import/extensions */
var _react = require('react');

@@ -22,2 +23,4 @@

/* eslint-enable import/no-unresolved, import/extensions */
/* eslint-disable no-underscore-dangle */

@@ -24,0 +27,0 @@

@@ -41,8 +41,8 @@ 'use strict';

var _initializeNetwork = require('./initializeNetwork');
var _initializeNetworkHelpers = require('./initializeNetworkHelpers');
Object.defineProperty(exports, 'initializeNetwork', {
Object.defineProperty(exports, 'initializeNetworkHelpers', {
enumerable: true,
get: function get() {
return _interopRequireDefault(_initializeNetwork).default;
return _interopRequireDefault(_initializeNetworkHelpers).default;
}

@@ -49,0 +49,0 @@ });

@@ -7,4 +7,6 @@ 'use strict';

// TODO: manage token so that defaults can be used as-is. Right now they are just an example.
var DEFAULT_NETWORK_HELPERS = {
getToken: function getToken() {
return 'token';
},
requestGET: function requestGET() {

@@ -14,3 +16,4 @@ return {

headers: {
Accept: 'application/json'
Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken()
}

@@ -24,2 +27,3 @@ };

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -35,2 +39,3 @@ },

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -46,2 +51,3 @@ },

Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken(),
'Content-Type': 'application/json'

@@ -56,6 +62,8 @@ },

headers: {
Accept: 'application/json'
Accept: 'application/json',
Authorization: 'Bearer ' + this.getToken()
}
};
},
handleStatusCode: function handleStatusCode(response) {

@@ -74,61 +82,58 @@ if (response) {

},
handleError: function handleError() {
return function () {
var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(err, dispatch) {
var error;
return regeneratorRuntime.wrap(function _callee$(_context) {
while (1) {
switch (_context.prev = _context.next) {
case 0:
_context.prev = 0;
// eslint-disable-next-line no-unused-vars
handleError: function () {
var _ref = _asyncToGenerator( /*#__PURE__*/regeneratorRuntime.mark(function _callee(err, dispatch) {
var error;
return regeneratorRuntime.wrap(function _callee$(_context) {
while (1) {
switch (_context.prev = _context.next) {
case 0:
_context.prev = 0;
if (!(err && err.response)) {
_context.next = 8;
break;
}
if (!(err && err.response)) {
_context.next = 8;
break;
}
_context.next = 4;
return err.response.json();
_context.next = 4;
return err.response.json();
case 4:
error = _context.sent;
case 4:
error = _context.sent;
if (dispatch) {
// dispatch some action to warn the user about the error
} else {
// eslint-disable-next-line no-alert
alert(error.message);
}
_context.next = 9;
break;
// dispatch some action to warn the user about the error
case 8:
// eslint-disable-next-line no-console
console.error(err);
// eslint-disable-next-line no-console
console.error(error);
_context.next = 9;
break;
case 9:
_context.next = 14;
break;
case 8:
// eslint-disable-next-line no-console
console.error(err);
case 11:
_context.prev = 11;
_context.t0 = _context['catch'](0);
case 9:
_context.next = 14;
break;
// eslint-disable-next-line no-console
console.error(_context.t0);
case 11:
_context.prev = 11;
_context.t0 = _context['catch'](0);
case 14:
case 'end':
return _context.stop();
}
// eslint-disable-next-line no-console
console.error(_context.t0);
case 14:
case 'end':
return _context.stop();
}
}, _callee, undefined, [[0, 11]]);
}));
}
}, _callee, undefined, [[0, 11]]);
}));
return function (_x, _x2) {
return _ref.apply(this, arguments);
};
}();
}
return function handleError(_x, _x2) {
return _ref.apply(this, arguments);
};
}()
};

@@ -135,0 +140,0 @@

@@ -6,2 +6,4 @@ 'use strict';

var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
var _getDefaultNetworkHelpers = require('./getDefaultNetworkHelpers');

@@ -13,10 +15,12 @@

var networkHelpers = void 0;
var DEFAULT_NETWORK_HELPERS = (0, _getDefaultNetworkHelpers2.default)();
var networkHelpers = DEFAULT_NETWORK_HELPERS;
var setNetworkHelpers = exports.setNetworkHelpers = function setNetworkHelpers(helpers) {
networkHelpers = helpers;
networkHelpers = helpers ? _extends({}, DEFAULT_NETWORK_HELPERS, helpers) : DEFAULT_NETWORK_HELPERS;
};
var getNetworkHelpers = exports.getNetworkHelpers = function getNetworkHelpers() {
return networkHelpers || (0, _getDefaultNetworkHelpers2.default)();
return networkHelpers;
};
{
"name": "@brigad/redux-rest-easy",
"version": "1.0.0",
"description": "Redux framework handling network requests, state management, caching, selectors and much more",
"version": "2.0.0",
"description": "Redux/React/React Native framework generating actions, reducers and selectors to perform network requests",
"main": "lib/index.js",

@@ -45,2 +45,3 @@ "module": "es/indexjs",

"scripts": {
"prepublishOnly": "yarn build:clean && yarn build",
"modules:clean": "rimraf node_modules",

@@ -53,3 +54,2 @@ "build": "yarn build:commonjs && yarn build:es && yarn build:umd && yarn build:umd:min",

"build:clean": "rimraf lib dist es coverage",
"prepare": "yarn build:clean && yarn build",
"lint": "eslint src",

@@ -60,6 +60,7 @@ "test": "jest",

"test:cov": "yarn test --coverage",
"ci": "yarn ci:eslint && yarn ci:jest && yarn ci:codecov",
"ci:eslint": "yarn lint",
"ci:jest": "cross-env CI=true JEST_JUNIT_OUTPUT='junit/jest.xml' yarn test --ci --coverage --expand --forceExit",
"ci:codecov": "codecov -f coverage/coverage-final.json",
"ci:test": "yarn ci:test:eslint && yarn ci:test:jest && yarn ci:test:codecov",
"ci:test:eslint": "yarn lint",
"ci:test:jest": "cross-env CI=true JEST_JUNIT_OUTPUT='junit/jest.xml' yarn test --ci --coverage --expand --forceExit",
"ci:test:codecov": "codecov -f coverage/coverage-final.json",
"ci:publish": "yarn semantic-release",
"prettify": "prettier-eslint --write \"./src/**/*.js\"",

@@ -73,3 +74,3 @@ "contributors:add": "all-contributors add",

"lodash.mergewith": "4.6.1",
"murmur-hash": "^1.0.0",
"murmur-hash": "1.0.0",
"qs": "6.5.1",

@@ -86,6 +87,6 @@ "re-reselect": "1.0.1",

"babel-plugin-external-helpers": "6.22.0",
"babel-plugin-transform-object-rest-spread": "6.26.0",
"babel-preset-env": "1.6.1",
"babel-preset-react": "6.24.1",
"babel-preset-stage-0": "6.24.1",
"babel-preset-stage-2": "6.24.1",
"codecov": "3.0.0",
"cross-env": "5.1.3",

@@ -101,3 +102,3 @@ "eslint": "4.17.0",

"mockdate": "2.0.2",
"moment": "^2.20.1",
"moment": "2.20.1",
"prettier-eslint-cli": "4.7.0",

@@ -111,3 +112,4 @@ "rimraf": "2.6.2",

"rollup-plugin-replace": "2.0.0",
"rollup-plugin-uglify": "3.0.0"
"rollup-plugin-uglify": "3.0.0",
"semantic-release": "12.4.1"
},

@@ -114,0 +116,0 @@ "peerDependencies": {

# ⛳ @brigad/redux-rest-easy
React/Redux framework generating actions, reducers and selectors to perform network requests
Redux/React/React Native framework generating actions, reducers and selectors to perform network requests
[![CircleCI][circle-ci-badge]][circle-ci]
[![Codecov][codecov-badge]][codecov]
[![version][version-badge]][package]

@@ -10,2 +12,3 @@ [![MIT License][license-badge]][license]

[![Code of Conduct][coc-badge]][coc]
[![code style: prettier][prettier-badge]][prettier]
[![Star on GitHub][github-star-badge]][github-star]

@@ -50,3 +53,3 @@

reset,
initializeNetwork,
initializeNetworkHelpers,
} from '@brigad/redux-rest-easy';

@@ -59,3 +62,3 @@ ```

* [reset](./docs/api/reset.md) - reset `redux-rest-easy`'s whole state (you can reset parts of the state with actions generated by `createResource`)
* [initializeNetwork](./docs/api/initializeNetwork.md) - provide your own network handling functions (optional, fallback to included defaults)
* [initializeNetworkHelpers](./docs/api/initializeNetworkHelpers.md) - provide your own network handlers (optional, fallback to included defaults)

@@ -124,3 +127,2 @@ ## Internals

state = {
success: false,
error: false,

@@ -134,7 +136,7 @@ };

onSuccess = () => {
this.setState({ success: true, error: false });
this.setState({ error: false });
};
onError = () => {
this.setState({ success: false, error: true });
this.setState({ error: true });
};

@@ -153,7 +155,3 @@

return (
<div>
<Users items={this.props.users} />
</div>
);
return <Users items={this.props.users} />;
}

@@ -177,5 +175,5 @@ }

Redux-rest-easy assumes you are using [react](https://github.com/facebook/react) and [react-redux](https://github.com/reactjs/react-redux).
Redux-rest-easy assumes you are using [react][react] (or [react-native][react-native]) and [react-redux][react-redux].
Redux-rest-easy also uses [redux-thunk](https://github.com/gaearon/redux-thunk) to handle async actions, and therefore requires you to use redux-thunk's middleware in your store. If you are already using redux-thunk, then you have nothing more to do. Else, follow [redux-thunk's docs](https://github.com/gaearon/redux-thunk#installation) for a quick setup.
Redux-rest-easy also uses [redux-thunk][redux-thunk] to handle async actions, and therefore requires you to use redux-thunk's middleware in your store. If you are already using redux-thunk, then you have nothing more to do. Else, follow [redux-thunk's docs][redux-thunk-installation] for a quick setup.

@@ -197,2 +195,6 @@ ## Contributors

[circle-ci-badge]: https://img.shields.io/circleci/token/75524c993d9de495223af8fa371cf086aa69793d/project/github/Brigad/redux-rest-easy/master.svg?style=flat-square&label=build
[circle-ci]: https://circleci.com/gh/Brigad/redux-rest-easy
[codecov-badge]: https://img.shields.io/codecov/c/github/Brigad/redux-rest-easy.svg
[codecov]: https://codecov.io/gh/Brigad/redux-rest-easy
[version-badge]: https://img.shields.io/npm/v/@brigad/redux-rest-easy.svg?style=flat-square

@@ -206,5 +208,12 @@ [package]: https://www.npmjs.com/package/@brigad/redux-rest-easy

[coc]: https://github.com/Brigad/redux-rest-easy/blob/master/other/CODE_OF_CONDUCT.md
[prettier-badge]: https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square
[prettier]: https://github.com/prettier/prettier
[github-star-badge]: https://img.shields.io/github/stars/Brigad/redux-rest-easy.svg?style=social
[github-star]: https://github.com/Brigad/redux-rest-easy/stargazers
[react]: https://github.com/facebook/react
[react-native]: https://github.com/facebook/react-native
[react-redux]: https://github.com/reactjs/react-redux
[redux-thunk]: https://github.com/gaearon/redux-thunk
[redux-thunk-installation]: https://github.com/gaearon/redux-thunk#installation
[emojis]: https://github.com/kentcdodds/all-contributors#emoji-key
[all-contributors]: https://github.com/kentcdodds/all-contributors

@@ -0,3 +1,5 @@

/* eslint-disable import/no-unresolved, import/extensions */
import React from 'react';
import { connect } from 'react-redux';
/* eslint-enable import/no-unresolved, import/extensions */

@@ -4,0 +6,0 @@ /* eslint-disable no-underscore-dangle */

@@ -5,2 +5,4 @@ export { default as connect } from './connect';

export { default as reset } from './reset';
export { default as initializeNetwork } from './initializeNetwork';
export {
default as initializeNetworkHelpers,
} from './initializeNetworkHelpers';

@@ -1,39 +0,54 @@

// TODO: manage token so that defaults can be used as-is. Right now they are just an example.
const DEFAULT_NETWORK_HELPERS = {
requestGET: () => ({
method: 'GET',
headers: {
Accept: 'application/json',
},
}),
requestPATCH: body => ({
method: 'PATCH',
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
},
body,
}),
requestPUT: body => ({
method: 'PUT',
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
},
body,
}),
requestPOST: body => ({
method: 'POST',
headers: {
Accept: 'application/json',
'Content-Type': 'application/json',
},
body,
}),
requestDELETE: () => ({
method: 'DELETE',
headers: {
Accept: 'application/json',
},
}),
getToken: () => 'token',
requestGET() {
return {
method: 'GET',
headers: {
Accept: 'application/json',
Authorization: `Bearer ${this.getToken()}`,
},
};
},
requestPATCH(body) {
return {
method: 'PATCH',
headers: {
Accept: 'application/json',
Authorization: `Bearer ${this.getToken()}`,
'Content-Type': 'application/json',
},
body,
};
},
requestPUT(body) {
return {
method: 'PUT',
headers: {
Accept: 'application/json',
Authorization: `Bearer ${this.getToken()}`,
'Content-Type': 'application/json',
},
body,
};
},
requestPOST(body) {
return {
method: 'POST',
headers: {
Accept: 'application/json',
Authorization: `Bearer ${this.getToken()}`,
'Content-Type': 'application/json',
},
body,
};
},
requestDELETE() {
return {
method: 'DELETE',
headers: {
Accept: 'application/json',
Authorization: `Bearer ${this.getToken()}`,
},
};
},
handleStatusCode: (response) => {

@@ -52,3 +67,4 @@ if (response) {

},
handleError: () => async (err, dispatch) => {
// eslint-disable-next-line no-unused-vars
handleError: async (err, dispatch) => {
try {

@@ -58,8 +74,6 @@ if (err && err.response) {

if (dispatch) {
// dispatch some action to warn the user about the error
} else {
// eslint-disable-next-line no-alert
alert(error.message);
}
// dispatch some action to warn the user about the error
// eslint-disable-next-line no-console
console.error(error);
} else {

@@ -66,0 +80,0 @@ // eslint-disable-next-line no-console

@@ -1,10 +0,13 @@

import defaultNetworkHelpers from './getDefaultNetworkHelpers';
import getDefaultNetworkHelpers from './getDefaultNetworkHelpers';
let networkHelpers;
const DEFAULT_NETWORK_HELPERS = getDefaultNetworkHelpers();
let networkHelpers = DEFAULT_NETWORK_HELPERS;
export const setNetworkHelpers = (helpers) => {
networkHelpers = helpers;
networkHelpers = helpers
? { ...DEFAULT_NETWORK_HELPERS, ...helpers }
: DEFAULT_NETWORK_HELPERS;
};
export const getNetworkHelpers = () =>
networkHelpers || defaultNetworkHelpers();
export const getNetworkHelpers = () => networkHelpers;

Sorry, the diff of this file is too big to display

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