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

@airma/core

Package Overview
Dependencies
Maintainers
1
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@airma/core - npm Package Compare versions

Comparing version 17.1.2 to 17.2.0

2

dist/index.js

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

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports["@airma/core"]=e():t["@airma/core"]=e()}(self,(function(){return function(){"use strict";var t={d:function(e,n){for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o:function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r:function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};function n(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function c(t,e){if(t){if("string"==typeof t)return o(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function u(t){return function(t){if(Array.isArray(t))return o(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||c(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,c=[],u=!0,i=!1;try{for(n=n.call(t);!(u=(r=n.next()).done)&&(c.push(r.value),!e||c.length!==e);u=!0);}catch(t){i=!0,o=t}finally{try{u||null==n.return||n.return()}finally{if(i)throw o}}return c}}(t,e)||c(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function f(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?a(Object(r),!0).forEach((function(e){n(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function s(t,e,n,r){var o=Object.keys(n),c={};return o.forEach((function(n){c[n]={get:function(){return r.get?r.get(t,n,e):t[n]},set:function(o){if(r.set){if(!r.set(t,n,o,e))throw new Error("".concat(n," in proxy target is not mutable"))}else t[n]=o}}})),c}t.r(e),t.d(e,{createModel:function(){return O},createProxy:function(){return y},createStore:function(){return j},factory:function(){return g},shallowEqual:function(){return p}});var y=function(t,e){return"function"!=typeof Proxy?function(t,e){var n={},r=s(t,n,t,e),o=s(t,n,Object.getPrototypeOf(t),e);return Object.defineProperties(n,f(f({},o),r)),n}(t,e):new Proxy(t,e)};function l(t){return t&&"object"===r(t)}function p(t,e){if(Object.is(t,e))return!0;if(!l(t)||!l(e))return!1;var n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;var o=t,c=e;return!n.some((function(t){return!Object.prototype.hasOwnProperty.call(c,t)}))&&!r.some((function(t){var e=c[t],n=o[t];return!Object.is(e,n)}))}function b(t){var e={};return t.forEach((function(t){var n=i(t,2),r=n[0],o=n[1];e[r]=o})),{get:function(t){return e[t]}}}function d(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function h(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?d(Object(r),!0).forEach((function(e){n(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function v(t){return function(e){u(t.dispatches).forEach((function(t){t(e)}))}}function O(t,e,n){var r=t(e),o={current:r,reducer:t,dispatch:null,dispatches:[],cacheMethods:{},state:e,cacheState:null,controlled:!!n};function c(t,e){var n=o.state,r=!(!e||!e.isDefault),c=!(!e||!e.ignoreDispatch);if(!r||!o.cacheState){var u=e?e.state:n;o.reducer=t,o.state=u,o.cacheState=e&&e.cache?{state:e.state}:o.cacheState,o.current=t(o.state),n===o.state||r||c||v(o)({state:o.state,type:""})}}return{agent:y(r,{get:function(t,e){var n=o.current[e];return Object.prototype.hasOwnProperty.call(o.current,e)&&"function"==typeof n?function(t,e){if(t.cacheMethods[e])return t.cacheMethods[e];var n=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];function c(e){v(t)(e)}var u=t.current[e].apply(void 0,r),i=t.reducer;return t.controlled?(c({type:e,state:u}),u):(t.current=i(u),t.state=u,t.cacheState={state:u},c({type:e,state:u}),u)};return t.cacheMethods[e]=n,n}(o,e):n}}),getCacheState:function(){return o.cacheState},getState:function(){return o.state},update:c,updateState:function(t){c(o.reducer,{state:t,cache:!0})},notice:function(){v(o)({state:o.state,type:""})},connect:function(t){var e=o.dispatches;!t||e.indexOf(t)>=0||e.push(t)},disconnect:function(t){if(t){var e=o.dispatches,n=e.indexOf(t);n<0||e.splice(n,1)}else o.dispatches=[]}}}function g(t,e){var n=function(e){return t(e)};return n.creation=function(){return O(n,e)},n.pipe=function(t){var e=function(e){return t(e)};return e.getSourceFrom=function(){return n},e},n}function m(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if("function"==typeof t&&"function"==typeof t.creation)return[{key:e.join("."),keys:e,factory:t,connection:t.creation()}];if(!t||"object"!==r(t))return[];var n=[],o=t,c=Object.keys(o);return c.forEach((function(t){var r=m(o[t],e.concat(t));n.push.apply(n,u(r))})),n}function j(t){var e=t;function n(t){var e=t.map((function(t){return t.connection})),n=function(t){return{get:function(e){var n=t.find((function(t){return t.factory===e||t.sourceFactory===e}));return n?n.connection:void 0}}}(t);return{collections:t,connections:e,instances:n}}var r=m(t),o=n(r),c={update:function(e){if(e===t)return h({},c);var i=m(e),a=n(function(t,e){var n=b(e.map((function(t){return[t.key,{connection:t.connection,factory:t.factory}]}))),r=b(t.map((function(t){return[t.key,{connection:t.connection,factory:t.factory}]}))),o=e.filter((function(t){var e=t.key;return!r.get(e)})),c=t.filter((function(t){var e=t.key;return!n.get(e)})),i=t.map((function(t){var e=t.key,r=t.connection,o=n.get(e);if(o){var c=o.connection,u=null==r.getCacheState()?c.getState():r.getState();return r.update(o.factory,{state:u}),h(h({},t),{},{factory:o.factory,sourceFactory:t.factory})}})).filter((function(t){return!!t}));return c.forEach((function(t){return t.connection.disconnect()})),[].concat(u(o),u(i))}(r,i)),f=a.instances,s=a.connections,y=a.collections;return o.instances=f,o.connections=s,o.collections=y,h({},c)},get:function(t){return o.instances.get(t)},equal:function(t){return t===e},destroy:function(){o.connections.forEach((function(t){return t.disconnect()}))}};return h({},c)}return e}()}));
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports["@airma/core"]=e():t["@airma/core"]=e()}(self,(function(){return function(){"use strict";var t={d:function(e,n){for(var r in n)t.o(n,r)&&!t.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:n[r]})},o:function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r:function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})}},e={};function n(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function r(t){return r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r(t)}function o(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function c(t,e){if(t){if("string"==typeof t)return o(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);return"Object"===n&&t.constructor&&(n=t.constructor.name),"Map"===n||"Set"===n?Array.from(t):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?o(t,e):void 0}}function u(t){return function(t){if(Array.isArray(t))return o(t)}(t)||function(t){if("undefined"!=typeof Symbol&&null!=t[Symbol.iterator]||null!=t["@@iterator"])return Array.from(t)}(t)||c(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function i(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,o,c=[],u=!0,i=!1;try{for(n=n.call(t);!(u=(r=n.next()).done)&&(c.push(r.value),!e||c.length!==e);u=!0);}catch(t){i=!0,o=t}finally{try{u||null==n.return||n.return()}finally{if(i)throw o}}return c}}(t,e)||c(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function a(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function f(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?a(Object(r),!0).forEach((function(e){n(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):a(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function s(t,e,n,r){var o=Object.keys(n),c={};return o.forEach((function(n){c[n]={get:function(){return r.get?r.get(t,n,e):t[n]},set:function(o){if(r.set){if(!r.set(t,n,o,e))throw new Error("".concat(n," in proxy target is not mutable"))}else t[n]=o}}})),c}t.r(e),t.d(e,{createModel:function(){return O},createProxy:function(){return y},createStore:function(){return j},factory:function(){return g},shallowEqual:function(){return p}});var y=function(t,e){return"function"!=typeof Proxy?function(t,e){var n={},r=s(t,n,t,e),o=s(t,n,Object.getPrototypeOf(t),e);return Object.defineProperties(n,f(f({},o),r)),n}(t,e):new Proxy(t,e)};function l(t){return t&&"object"===r(t)}function p(t,e){if(Object.is(t,e))return!0;if(!l(t)||!l(e))return!1;var n=Object.keys(t),r=Object.keys(e);if(n.length!==r.length)return!1;var o=t,c=e;return!n.some((function(t){return!Object.prototype.hasOwnProperty.call(c,t)}))&&!r.some((function(t){var e=c[t],n=o[t];return!Object.is(e,n)}))}function b(t){var e={};return t.forEach((function(t){var n=i(t,2),r=n[0],o=n[1];e[r]=o})),{get:function(t){return e[t]}}}function d(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,r)}return n}function h(t){for(var e=1;e<arguments.length;e++){var r=null!=arguments[e]?arguments[e]:{};e%2?d(Object(r),!0).forEach((function(e){n(t,e,r[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(r)):d(Object(r)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(r,e))}))}return t}function v(t){return function(e){u(t.dispatches).forEach((function(t){t(e)}))}}function O(t,e,n){var r=t(e),o={current:r,reducer:t,dispatch:null,dispatches:[],cacheMethods:{},state:e,cacheState:null,controlled:!!n};function c(t,e){var n=o.state,r=!(!e||!e.isDefault),c=!(!e||!e.ignoreDispatch);if(!r||!o.cacheState){var u=e?e.state:n;o.reducer=t,o.state=u,o.cacheState=e&&e.cache?{state:e.state}:o.cacheState,o.current=t(o.state),n===o.state||r||c||v(o)({state:o.state,type:""})}}return{agent:y(r,{get:function(t,e){var n=o.current[e];return Object.prototype.hasOwnProperty.call(o.current,e)&&"function"==typeof n?function(t,e){if(t.cacheMethods[e])return t.cacheMethods[e];var n=function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];function c(e){v(t)(e)}var u=t.current[e].apply(void 0,r),i=t.reducer;return t.controlled?(c({type:e,state:u}),u):(t.current=i(u),t.state=u,t.cacheState={state:u},c({type:e,state:u}),u)};return t.cacheMethods[e]=n,n}(o,e):n}}),getCacheState:function(){return o.cacheState},getState:function(){return o.state},getCurrent:function(){return o.current},update:c,updateState:function(t){c(o.reducer,{state:t,cache:!0})},notice:function(){v(o)({state:o.state,type:""})},connect:function(t){var e=o.dispatches;!t||e.indexOf(t)>=0||e.push(t)},disconnect:function(t){if(t){var e=o.dispatches,n=e.indexOf(t);n<0||e.splice(n,1)}else o.dispatches=[]}}}function g(t,e){var n=function(e){return t(e)};return n.creation=function(){return O(n,e)},n.pipe=function(t){var e=function(e){return t(e)};return e.getSourceFrom=function(){return n},e},n}function m(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if("function"==typeof t&&"function"==typeof t.creation)return[{key:e.join("."),keys:e,factory:t,connection:t.creation()}];if(!t||"object"!==r(t))return[];var n=[],o=t,c=Object.keys(o);return c.forEach((function(t){var r=m(o[t],e.concat(t));n.push.apply(n,u(r))})),n}function j(t){var e=t;function n(t){var e=t.map((function(t){return t.connection})),n=function(t){return{get:function(e){var n=t.find((function(t){return t.factory===e||t.sourceFactory===e}));return n?n.connection:void 0}}}(t);return{collections:t,connections:e,instances:n}}var r=m(t),o=n(r),c={update:function(e){if(e===t)return h({},c);var i=m(e),a=n(function(t,e){var n=b(e.map((function(t){return[t.key,{connection:t.connection,factory:t.factory}]}))),r=b(t.map((function(t){return[t.key,{connection:t.connection,factory:t.factory}]}))),o=e.filter((function(t){var e=t.key;return!r.get(e)})),c=t.filter((function(t){var e=t.key;return!n.get(e)})),i=t.map((function(t){var e=t.key,r=t.connection,o=n.get(e);if(o){var c=o.connection,u=null==r.getCacheState()?c.getState():r.getState();return r.update(o.factory,{state:u}),h(h({},t),{},{factory:o.factory,sourceFactory:t.factory})}})).filter((function(t){return!!t}));return c.forEach((function(t){return t.connection.disconnect()})),[].concat(u(o),u(i))}(r,i)),f=a.instances,s=a.connections,y=a.collections;return o.instances=f,o.connections=s,o.collections=y,h({},c)},get:function(t){return o.instances.get(t)},equal:function(t){return t===e},destroy:function(){o.connections.forEach((function(t){return t.disconnect()}))}};return h({},c)}return e}()}));

@@ -39,2 +39,3 @@ export declare type Action = {

getState(): S;
getCurrent(): T;
update: (

@@ -41,0 +42,0 @@ reducer: AirReducer<S, T>,

@@ -8,3 +8,3 @@ {

"name": "@airma/core",
"version": "17.1.2",
"version": "17.2.0",
"description": "This is the core for agent-reducer and airma",

@@ -11,0 +11,0 @@ "repository": {

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