invoker-core
Advanced tools
Comparing version 1.0.5 to 1.0.6
@@ -1,1 +0,1 @@ | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.InvokerDriver=void 0;var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_InvokerDriver=require("./InvokerDriver"),_InvokerDriver2=_interopRequireDefault(_InvokerDriver);function _interopRequireDefault(a){return a&&a.__esModule?a:{default:a}}var currentDriver=new _InvokerDriver2.default,before={},after={},Invoker={Attach:function b(a){return a instanceof _InvokerDriver2.default?void(currentDriver=a):void console.error("Driver is not an invoker driver")},Before:function c(a,b){_typeof(before[a])===void 0&&(before[a]=[]),before[a].push(b)},After:function c(a,b){_typeof(after[a])===void 0&&(after[a]=[]),after[a].push(b)},Call:function c(a,b){return before[a]&&before[a].forEach(function(a){return a()}),currentDriver.execute(a,b).then(function(){after[a]&&after[a].forEach(function(a){return a()})})}};exports.InvokerDriver=_InvokerDriver2.default,exports.default=Invoker; | ||
"use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.InvokerDriver=void 0;var _typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){return a&&"function"==typeof Symbol&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_InvokerDriver=require("./InvokerDriver"),_InvokerDriver2=_interopRequireDefault(_InvokerDriver);function _interopRequireDefault(a){return a&&a.__esModule?a:{default:a}}function _toConsumableArray(a){if(Array.isArray(a)){for(var b=0,c=Array(a.length);b<a.length;b++)c[b]=a[b];return c}return Array.from(a)}var currentDriver=new _InvokerDriver2.default,before={},after={},Invoker={Attach:function b(a){return a instanceof _InvokerDriver2.default?void(currentDriver=a):void console.error("Driver is not an invoker driver")},Before:function c(a,b){_typeof(before[a])===void 0&&(before[a]=[]),before[a]=[].concat(_toConsumableArray(before[a]),[b])},After:function c(a,b){_typeof(after[a])===void 0&&(after[a]=[]),after[a]=[].concat(_toConsumableArray(after[a]),[b])},Call:function c(a,b){return before[a]&&before[a].forEach(function(a){return a()}),currentDriver.execute(a,b).then(function(){after[a]&&after[a].forEach(function(a){return a()})})}};exports.InvokerDriver=_InvokerDriver2.default,exports.default=Invoker; |
{ | ||
"name": "invoker-core", | ||
"version": "1.0.5", | ||
"version": "1.0.6", | ||
"description": "InvokeJS is simple yet powerful endpoint proxy for your client", | ||
@@ -57,3 +57,5 @@ "main": "./lib/index.js", | ||
}, | ||
"dependencies": {} | ||
"dependencies": { | ||
"babel-plugin-transform-object-rest-spread": "^6.26.0" | ||
} | ||
} |
@@ -19,3 +19,3 @@ import InvokerDriver from "./InvokerDriver"; | ||
} | ||
before[target].push(handler); | ||
before[target] = [...before[target], handler]; | ||
}, | ||
@@ -26,3 +26,3 @@ After(target, handler) { | ||
} | ||
after[target].push(handler); | ||
after[target] = [...after[target], handler]; | ||
}, | ||
@@ -29,0 +29,0 @@ Call(target, params) { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
7712
1
+ Addedbabel-plugin-syntax-object-rest-spread@6.13.0(transitive)
+ Addedbabel-plugin-transform-object-rest-spread@6.26.0(transitive)
+ Addedbabel-runtime@6.26.0(transitive)
+ Addedcore-js@2.6.12(transitive)
+ Addedregenerator-runtime@0.11.1(transitive)