diff --git a/.eslintrc b/.eslintrc deleted file mode 100644 index 1d53468a..00000000 --- a/.eslintrc +++ /dev/null @@ -1,17 +0,0 @@ -{ - "extends": ["airbnb-base"], - "parser": "babel-eslint", - "parserOptions": { - "ecmaVersion": 2019, - "sourceType": "module" - }, - "rules": { - "no-param-reassign": "off", - "no-plusplus": "off", - "no-shadow": "off", - "no-underscore-dangle": "off", - "no-use-before-define": "off", - - "import/order": "off" - } -} diff --git a/dist/helpers.js b/dist/helpers.js index ac9731ce..9364bf60 100644 --- a/dist/helpers.js +++ b/dist/helpers.js @@ -1,12 +1,8 @@ "use strict"; -function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); } +var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); -function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } - -function _iterableToArrayLimit(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } - -function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; } +var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray")); function getDefaultResult(t, isObject) { return isObject ? t.objectExpression([]) : t.arrayExpression(); @@ -59,7 +55,27 @@ function getLoop(_ref) { } function getReduceResultStatement(t, handler, fn, result, value, key, iterable, path) { - if (t.isArrowFunctionExpression(handler)) { + function createRename(r, v, k, i) { + return function rename(_path) { + if (r) { + _path.scope.rename(r.name, result.name); + } + + if (v) { + _path.scope.rename(v.name, value.name); + } + + if (k) { + _path.scope.rename(k.name, key.name); + } + + if (i) { + _path.scope.rename(i.name, iterable.name); + } + }; + } + + if (t.isArrowFunctionExpression(handler) || t.isFunctionExpression(handler)) { var body = handler.body; if (t.isBlockStatement(body)) { @@ -67,33 +83,23 @@ function getReduceResultStatement(t, handler, fn, result, value, key, iterable, body = body.body; if (body.length === 1) { - var _handler$params = _slicedToArray(handler.params, 4), + var _handler$params = (0, _slicedToArray2["default"])(handler.params, 4), r = _handler$params[0], v = _handler$params[1], k = _handler$params[2], i = _handler$params[3]; - var parentPath = path.parentPath; var node = body[0]; - parentPath.traverse({ - ArrowFunctionExpression: function ArrowFunctionExpression(_path) { - if (r) { - _path.scope.rename(r.name, result.name); - } - - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - } - }); + + if (t.isArrowFunctionExpression(handler)) { + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(r, v, k, i) + }); + } else { + path.parentPath.traverse({ + FunctionExpression: createRename(r, v, k, i) + }); + } if (t.isExpression(node)) { return node; @@ -107,95 +113,43 @@ function getReduceResultStatement(t, handler, fn, result, value, key, iterable, return node.argument; } } - } else { - var _handler$params2 = _slicedToArray(handler.params, 4), + } else if (t.isExpression(body)) { + var _handler$params2 = (0, _slicedToArray2["default"])(handler.params, 4), _r = _handler$params2[0], _v = _handler$params2[1], _k = _handler$params2[2], - _i2 = _handler$params2[3]; - - var _parentPath = path.parentPath; - - _parentPath.traverse({ - ArrowFunctionExpression: function ArrowFunctionExpression(_path) { - if (_r) { - _path.scope.rename(_r.name, result.name); - } - - if (_v) { - _path.scope.rename(_v.name, value.name); - } + _i = _handler$params2[3]; - if (_k) { - _path.scope.rename(_k.name, key.name); - } - - if (_i2) { - _path.scope.rename(_i2.name, iterable.name); - } - } + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(_r, _v, _k, _i) }); - - if (t.isExpression(body)) { - return body; - } + return body; } } - if (t.isFunctionExpression(handler)) { - var _body = handler.body.body; - - if (_body.length === 1) { - var _handler$params3 = _slicedToArray(handler.params, 4), - _r2 = _handler$params3[0], - _v2 = _handler$params3[1], - _k2 = _handler$params3[2], - _i3 = _handler$params3[3]; - - var _parentPath2 = path.parentPath; - var _node = _body[0]; - - _parentPath2.traverse({ - FunctionExpression: function FunctionExpression(_path) { - if (_r2) { - _path.scope.rename(_r2.name, result.name); - } - - if (_v2) { - _path.scope.rename(_v2.name, value.name); - } - - if (_k2) { - _path.scope.rename(_k2.name, key.name); - } - - if (_i3) { - _path.scope.rename(_i3.name, iterable.name); - } - } - }); + var callExpression = t.callExpression(fn, [result, value, key, iterable]); + callExpression.__inlineLoopsMacroFallback = true; + return callExpression; +} - if (t.isExpression(_node)) { - return _node; +function getResultStatement(t, handler, fn, value, key, iterable, path) { + function createRename(v, k, i) { + return function rename(_path) { + if (v) { + _path.scope.rename(v.name, value.name); } - if (t.isExpressionStatement(_node)) { - return _node.expression; + if (k) { + _path.scope.rename(k.name, key.name); } - if (t.isReturnStatement(_node)) { - return _node.argument; + if (i) { + _path.scope.rename(i.name, iterable.name); } - } + }; } - var callExpression = t.callExpression(fn, [result, value, key, iterable]); - callExpression.__inlineLoopsMacroFallback = true; - return callExpression; -} - -function getResultStatement(t, handler, fn, value, key, iterable, path) { - if (t.isArrowFunctionExpression(handler)) { + if (t.isArrowFunctionExpression(handler) || t.isFunctionExpression(handler)) { var body = handler.body; if (t.isBlockStatement(body)) { @@ -203,28 +157,22 @@ function getResultStatement(t, handler, fn, value, key, iterable, path) { body = body.body; if (body.length === 1) { - var _handler$params4 = _slicedToArray(handler.params, 3), - v = _handler$params4[0], - k = _handler$params4[1], - i = _handler$params4[2]; + var _handler$params3 = (0, _slicedToArray2["default"])(handler.params, 3), + v = _handler$params3[0], + k = _handler$params3[1], + i = _handler$params3[2]; - var parentPath = path.parentPath; var node = body[0]; - parentPath.traverse({ - ArrowFunctionExpression: function ArrowFunctionExpression(_path) { - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - } - }); + + if (t.isArrowFunctionExpression(handler)) { + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(v, k, i) + }); + } else { + path.parentPath.traverse({ + FunctionExpression: createRename(v, k, i) + }); + } if (t.isExpression(node)) { return node; @@ -238,75 +186,16 @@ function getResultStatement(t, handler, fn, value, key, iterable, path) { return node.argument; } } - } else { - var _handler$params5 = _slicedToArray(handler.params, 3), - _v3 = _handler$params5[0], - _k3 = _handler$params5[1], - _i4 = _handler$params5[2]; - - var _parentPath3 = path.parentPath; - - _parentPath3.traverse({ - ArrowFunctionExpression: function ArrowFunctionExpression(_path) { - if (_v3) { - _path.scope.rename(_v3.name, value.name); - } - - if (_k3) { - _path.scope.rename(_k3.name, key.name); - } - - if (_i4) { - _path.scope.rename(_i4.name, iterable.name); - } - } - }); - - if (t.isExpression(body)) { - return body; - } - } - } - - if (t.isFunctionExpression(handler)) { - var _body2 = handler.body.body; - - if (_body2.length === 1) { - var _handler$params6 = _slicedToArray(handler.params, 3), - _v4 = _handler$params6[0], - _k4 = _handler$params6[1], - _i5 = _handler$params6[2]; - - var _parentPath4 = path.parentPath; - var _node2 = _body2[0]; - - _parentPath4.traverse({ - FunctionExpression: function FunctionExpression(_path) { - if (_v4) { - _path.scope.rename(_v4.name, value.name); - } - - if (_k4) { - _path.scope.rename(_k4.name, key.name); - } - - if (_i5) { - _path.scope.rename(_i5.name, iterable.name); - } - } + } else if (t.isExpression(body)) { + var _handler$params4 = (0, _slicedToArray2["default"])(handler.params, 3), + _v2 = _handler$params4[0], + _k2 = _handler$params4[1], + _i2 = _handler$params4[2]; + + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(_v2, _k2, _i2) }); - - if (t.isExpression(_node2)) { - return _node2; - } - - if (t.isExpressionStatement(_node2)) { - return _node2.expression; - } - - if (t.isReturnStatement(_node2)) { - return _node2.argument; - } + return body; } } diff --git a/dist/inline-loops.macro.js b/dist/inline-loops.macro.js index 479ff062..c1ecf27f 100644 --- a/dist/inline-loops.macro.js +++ b/dist/inline-loops.macro.js @@ -1,20 +1,10 @@ "use strict"; -function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _nonIterableRest(); } +var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault"); -function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } +var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray")); -function _iterableToArrayLimit(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"] != null) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } - -function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; } - -function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); } - -function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance"); } - -function _iterableToArray(iter) { if (Symbol.iterator in Object(iter) || Object.prototype.toString.call(iter) === "[object Arguments]") return Array.from(iter); } - -function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = new Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } } +var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray")); var _require = require('babel-plugin-macros'), createMacro = _require.createMacro, @@ -88,14 +78,14 @@ function inlineLoops(_ref) { objectCalls = _getCallTypes.objectCalls; if (isArrayOnly) { - return allMethods.push.apply(allMethods, _toConsumableArray(incrementingCalls).concat(_toConsumableArray(decrementingCalls))); + return allMethods.push.apply(allMethods, (0, _toConsumableArray2["default"])(incrementingCalls).concat((0, _toConsumableArray2["default"])(decrementingCalls))); } if (isObjectOnly) { - return allMethods.push.apply(allMethods, _toConsumableArray(objectCalls)); + return allMethods.push.apply(allMethods, (0, _toConsumableArray2["default"])(objectCalls)); } - return allMethods.push.apply(allMethods, _toConsumableArray(incrementingCalls).concat(_toConsumableArray(decrementingCalls), _toConsumableArray(objectCalls))); + return allMethods.push.apply(allMethods, (0, _toConsumableArray2["default"])(incrementingCalls).concat((0, _toConsumableArray2["default"])(decrementingCalls), (0, _toConsumableArray2["default"])(objectCalls))); }); allMethods.forEach(function (_ref2) { var path = _ref2.path; @@ -108,7 +98,7 @@ function inlineLoops(_ref) { var bContainer = b.container; if (aContainer.arguments) { - var _aContainer$arguments = _slicedToArray(aContainer.arguments, 1), + var _aContainer$arguments = (0, _slicedToArray2["default"])(aContainer.arguments, 1), iterableA = _aContainer$arguments[0]; if (t.isCallExpression(iterableA) && iterableA.callee.__inlineLoopsMacro && iterableA.callee === b.node) { @@ -117,7 +107,7 @@ function inlineLoops(_ref) { } if (bContainer.arguments) { - var _bContainer$arguments = _slicedToArray(bContainer.arguments, 1), + var _bContainer$arguments = (0, _slicedToArray2["default"])(bContainer.arguments, 1), iterableB = _bContainer$arguments[0]; if (t.isCallExpression(iterableB) && iterableB.callee.__inlineLoopsMacro && iterableB.callee === a.node) { @@ -170,7 +160,7 @@ function inlineLoops(_ref) { throw new MacroError('You cannot use spread arguments with the macro, please declare the arguments explicitly.'); } - var _args = _slicedToArray(args, 3), + var _args = (0, _slicedToArray2["default"])(args, 3), object = _args[0], handler = _args[1], initialValue = _args[2]; diff --git a/package.json b/package.json index 185cd863..8221a385 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,17 @@ "author": "Tony Quetano", "babel": { "plugins": [ - "babel-plugin-macros" + "babel-plugin-macros", + [ + "@babel/plugin-transform-runtime", + { + "absoluteRuntime": false, + "corejs": false, + "helpers": true, + "regenerator": false, + "useESModules": false + } + ] ], "presets": [ "@babel/preset-env" @@ -19,6 +29,8 @@ "devDependencies": { "@babel/cli": "^7.4.4", "@babel/core": "^7.4.5", + "@babel/plugin-external-helpers": "^7.2.0", + "@babel/plugin-transform-runtime": "^7.4.4", "@babel/preset-env": "^7.4.5", "@babel/preset-react": "^7.0.0", "@types/jest": "^24.0.13", @@ -32,6 +44,24 @@ "jest": "^24.8.0", "ts-jest": "^24.0.2" }, + "eslintConfig": { + "extends": [ + "airbnb-base" + ], + "parser": "babel-eslint", + "parserOptions": { + "ecmaVersion": 2019, + "sourceType": "module" + }, + "rules": { + "no-param-reassign": "off", + "no-plusplus": "off", + "no-shadow": "off", + "no-underscore-dangle": "off", + "no-use-before-define": "off", + "import/order": "off" + } + }, "homepage": "https://github.com/planttheidea/inline-loops.macro#readme", "jest": { "testPathIgnorePatterns": [ diff --git a/src/helpers.js b/src/helpers.js index 31ebba0b..97ea7efe 100644 --- a/src/helpers.js +++ b/src/helpers.js @@ -58,7 +58,27 @@ function getLoop({ } function getReduceResultStatement(t, handler, fn, result, value, key, iterable, path) { - if (t.isArrowFunctionExpression(handler)) { + function createRename(r, v, k, i) { + return function rename(_path) { + if (r) { + _path.scope.rename(r.name, result.name); + } + + if (v) { + _path.scope.rename(v.name, value.name); + } + + if (k) { + _path.scope.rename(k.name, key.name); + } + + if (i) { + _path.scope.rename(i.name, iterable.name); + } + }; + } + + if (t.isArrowFunctionExpression(handler) || t.isFunctionExpression(handler)) { let { body } = handler; if (t.isBlockStatement(body)) { @@ -67,28 +87,17 @@ function getReduceResultStatement(t, handler, fn, result, value, key, iterable, if (body.length === 1) { const [r, v, k, i] = handler.params; - const { parentPath } = path; const node = body[0]; - parentPath.traverse({ - ArrowFunctionExpression(_path) { - if (r) { - _path.scope.rename(r.name, result.name); - } - - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, - }); + if (t.isArrowFunctionExpression(handler)) { + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(r, v, k, i), + }); + } else { + path.parentPath.traverse({ + FunctionExpression: createRename(r, v, k, i), + }); + } if (t.isExpression(node)) { return node; @@ -102,75 +111,14 @@ function getReduceResultStatement(t, handler, fn, result, value, key, iterable, return node.argument; } } - } else { + } else if (t.isExpression(body)) { const [r, v, k, i] = handler.params; - const { parentPath } = path; - - parentPath.traverse({ - ArrowFunctionExpression(_path) { - if (r) { - _path.scope.rename(r.name, result.name); - } - - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, - }); - - if (t.isExpression(body)) { - return body; - } - } - } - if (t.isFunctionExpression(handler)) { - const { body } = handler.body; - - if (body.length === 1) { - const [r, v, k, i] = handler.params; - const { parentPath } = path; - const node = body[0]; - - parentPath.traverse({ - FunctionExpression(_path) { - if (r) { - _path.scope.rename(r.name, result.name); - } - - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(r, v, k, i), }); - if (t.isExpression(node)) { - return node; - } - - if (t.isExpressionStatement(node)) { - return node.expression; - } - - if (t.isReturnStatement(node)) { - return node.argument; - } + return body; } } @@ -182,7 +130,23 @@ function getReduceResultStatement(t, handler, fn, result, value, key, iterable, } function getResultStatement(t, handler, fn, value, key, iterable, path) { - if (t.isArrowFunctionExpression(handler)) { + function createRename(v, k, i) { + return function rename(_path) { + if (v) { + _path.scope.rename(v.name, value.name); + } + + if (k) { + _path.scope.rename(k.name, key.name); + } + + if (i) { + _path.scope.rename(i.name, iterable.name); + } + }; + } + + if (t.isArrowFunctionExpression(handler) || t.isFunctionExpression(handler)) { let { body } = handler; if (t.isBlockStatement(body)) { @@ -191,24 +155,17 @@ function getResultStatement(t, handler, fn, value, key, iterable, path) { if (body.length === 1) { const [v, k, i] = handler.params; - const { parentPath } = path; const node = body[0]; - parentPath.traverse({ - ArrowFunctionExpression(_path) { - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, - }); + if (t.isArrowFunctionExpression(handler)) { + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(v, k, i), + }); + } else { + path.parentPath.traverse({ + FunctionExpression: createRename(v, k, i), + }); + } if (t.isExpression(node)) { return node; @@ -222,67 +179,14 @@ function getResultStatement(t, handler, fn, value, key, iterable, path) { return node.argument; } } - } else { + } else if (t.isExpression(body)) { const [v, k, i] = handler.params; - const { parentPath } = path; - - parentPath.traverse({ - ArrowFunctionExpression(_path) { - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, - }); - if (t.isExpression(body)) { - return body; - } - } - } - - if (t.isFunctionExpression(handler)) { - const { body } = handler.body; - - if (body.length === 1) { - const [v, k, i] = handler.params; - const { parentPath } = path; - const node = body[0]; - - parentPath.traverse({ - FunctionExpression(_path) { - if (v) { - _path.scope.rename(v.name, value.name); - } - - if (k) { - _path.scope.rename(k.name, key.name); - } - - if (i) { - _path.scope.rename(i.name, iterable.name); - } - }, + path.parentPath.traverse({ + ArrowFunctionExpression: createRename(v, k, i), }); - if (t.isExpression(node)) { - return node; - } - - if (t.isExpressionStatement(node)) { - return node.expression; - } - - if (t.isReturnStatement(node)) { - return node.argument; - } + return body; } } diff --git a/yarn.lock b/yarn.lock index 15414120..f44a4a4c 100644 --- a/yarn.lock +++ b/yarn.lock @@ -243,6 +243,13 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.4.5.tgz#04af8d5d5a2b044a2a1bffacc1e5e6673544e872" integrity sha512-9mUqkL1FF5T7f0WDFfAoDdiMVPWsdD1gZYzSnaXsxUCUqzuch/8of9G3VUSNiZmMBoRxT3neyVsqeiL/ZPcjew== +"@babel/plugin-external-helpers@^7.2.0": + version "7.2.0" + resolved "https://registry.yarnpkg.com/@babel/plugin-external-helpers/-/plugin-external-helpers-7.2.0.tgz#7f4cb7dee651cd380d2034847d914288467a6be4" + integrity sha512-QFmtcCShFkyAsNtdCM3lJPmRe1iB+vPZymlB4LnDIKEBj2yKQLQKtoxXxJ8ePT5fwMl4QGg303p4mB0UsSI2/g== + dependencies: + "@babel/helper-plugin-utils" "^7.0.0" + "@babel/plugin-proposal-async-generator-functions@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.2.0.tgz#b289b306669dce4ad20b0252889a15768c9d417e" @@ -549,6 +556,16 @@ dependencies: "@babel/helper-plugin-utils" "^7.0.0" +"@babel/plugin-transform-runtime@^7.4.4": + version "7.4.4" + resolved "https://registry.yarnpkg.com/@babel/plugin-transform-runtime/-/plugin-transform-runtime-7.4.4.tgz#a50f5d16e9c3a4ac18a1a9f9803c107c380bce08" + integrity sha512-aMVojEjPszvau3NRg+TIH14ynZLvPewH4xhlCW1w6A3rkxTS1m4uwzRclYR9oS+rl/dr+kT+pzbfHuAWP/lc7Q== + dependencies: + "@babel/helper-module-imports" "^7.0.0" + "@babel/helper-plugin-utils" "^7.0.0" + resolve "^1.8.1" + semver "^5.5.1" + "@babel/plugin-transform-shorthand-properties@^7.2.0": version "7.2.0" resolved "https://registry.yarnpkg.com/@babel/plugin-transform-shorthand-properties/-/plugin-transform-shorthand-properties-7.2.0.tgz#6333aee2f8d6ee7e28615457298934a3b46198f0" @@ -881,9 +898,9 @@ "@babel/types" "^7.0.0" "@types/babel__traverse@*", "@types/babel__traverse@^7.0.6": - version "7.0.6" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.6.tgz#328dd1a8fc4cfe3c8458be9477b219ea158fd7b2" - integrity sha512-XYVgHF2sQ0YblLRMLNPB3CkFMewzFmlDsH/TneZFHUXDlABQgh88uOxuez7ZcXxayLFrqLwtDH1t+FmlFwNZxw== + version "7.0.7" + resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.0.7.tgz#2496e9ff56196cc1429c72034e07eab6121b6f3f" + integrity sha512-CeBpmX1J8kWLcDEnI3Cl2Eo6RfbGvzUctA+CjZUhOKDFbLfcr7fc4usEqLNWetrlJd7RhAkyYe2czXop4fICpw== dependencies: "@babel/types" "^7.3.0" @@ -913,9 +930,9 @@ integrity sha512-yALhelO3i0hqZwhjtcr6dYyaLoCHbAMshwtj6cGxTvHZAKXHsYGdff6E8EPw3xLKY0ELUTQ69Q1rQiJENnccMA== "@types/jest@^24.0.13": - version "24.0.13" - resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.0.13.tgz#10f50b64cb05fb02411fbba49e9042a3a11da3f9" - integrity sha512-3m6RPnO35r7Dg+uMLj1+xfZaOgIHHHut61djNjzwExXN4/Pm9has9C6I1KMYSfz7mahDhWUOVg4HW/nZdv5Pww== + version "24.0.14" + resolved "https://registry.yarnpkg.com/@types/jest/-/jest-24.0.14.tgz#bb40fec243164b2def5cfaddd0cb4d4e958c5c1c" + integrity sha512-IxS2AO0nOr4zrpKfRCxobQUb1bSK6ejodZ7odCzHXMjsASCI8J10N8qVQhrCjvJTc3bUjGGeuD+ytKZqyhajqQ== dependencies: "@types/jest-diff" "*" @@ -1168,13 +1185,13 @@ babel-plugin-macros@^2.0.0: resolve "^1.10.0" babel-plugin-tester@^6.2.1: - version "6.2.1" - resolved "https://registry.yarnpkg.com/babel-plugin-tester/-/babel-plugin-tester-6.2.1.tgz#b9195bfb3c868bd8316a1108c0f35b7f3fb84fcc" - integrity sha512-ELsxMOKGzgVkxWnbd4g9nnbbymQFjGrV9bMO3isuc7KIcdoVm8JoSf252DCoFr4iuS/mMmemM9Q8x+UD37U+6g== + version "6.4.0" + resolved "https://registry.yarnpkg.com/babel-plugin-tester/-/babel-plugin-tester-6.4.0.tgz#cdbc430794c375bf4c207a0287a00a68346529e9" + integrity sha512-Eyr6YmDuKRStZX6Jamv+C0IW40RxiJLJb6ogaf0jNcIwZ+/r9Nq2vaDUTZgWLps+bQBMTmn6rtHD3zJQecF3nA== dependencies: common-tags "^1.4.0" invariant "^2.2.2" - lodash.merge "^4.6.0" + lodash.mergewith "^4.6.0" path-exists "^3.0.0" strip-indent "^2.0.0" @@ -1252,7 +1269,7 @@ browser-resolve@^1.11.3: dependencies: resolve "1.1.7" -browserslist@^4.6.0: +browserslist@^4.6.0, browserslist@^4.6.2: version "4.6.2" resolved "https://registry.yarnpkg.com/browserslist/-/browserslist-4.6.2.tgz#574c665950915c2ac73a4594b8537a9eba26203f" integrity sha512-2neU/V0giQy9h3XMPwLhEY3+Ao0uHSwHvU8Q1Ea6AgLVL1sXbX3dzPrJ8NWe5Hi4PoTkCYXOtVR9rfRLI0J/8Q== @@ -1500,18 +1517,18 @@ copy-descriptor@^0.1.0: integrity sha1-Z29us8OZl8LuGsOpJP1hJHSPV40= core-js-compat@^3.1.1: - version "3.1.3" - resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.1.3.tgz#0cc3ba4c7f62928c2837e1cffbe8dc78b4f1ae14" - integrity sha512-EP018pVhgwsKHz3YoN1hTq49aRe+h017Kjz0NQz3nXV0cCRMvH3fLQl+vEPGr4r4J5sk4sU3tUC7U1aqTCeJeA== + version "3.1.4" + resolved "https://registry.yarnpkg.com/core-js-compat/-/core-js-compat-3.1.4.tgz#e4d0c40fbd01e65b1d457980fe4112d4358a7408" + integrity sha512-Z5zbO9f1d0YrJdoaQhphVAnKPimX92D6z8lCGphH89MNRxlL1prI9ExJPqVwP0/kgkQCv8c4GJGT8X16yUncOg== dependencies: - browserslist "^4.6.0" - core-js-pure "3.1.3" - semver "^6.1.0" + browserslist "^4.6.2" + core-js-pure "3.1.4" + semver "^6.1.1" -core-js-pure@3.1.3: - version "3.1.3" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.1.3.tgz#4c90752d5b9471f641514f3728f51c1e0783d0b5" - integrity sha512-k3JWTrcQBKqjkjI0bkfXS0lbpWPxYuHWfMMjC1VDmzU4Q58IwSbuXSo99YO/hUHlw/EB4AlfA2PVxOGkrIq6dA== +core-js-pure@3.1.4: + version "3.1.4" + resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.1.4.tgz#5fa17dc77002a169a3566cc48dc774d2e13e3769" + integrity sha512-uJ4Z7iPNwiu1foygbcZYJsJs1jiXrTTCvxfLDXNhI/I+NHbSIEyr548y4fcsCEyWY0XgfAG/qqaunJ1SThHenA== core-util-is@1.0.2, core-util-is@~1.0.0: version "1.0.2" @@ -1693,9 +1710,9 @@ ecc-jsbn@~0.1.1: safer-buffer "^2.1.0" electron-to-chromium@^1.3.150: - version "1.3.155" - resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.155.tgz#ebf0cc8eeaffd6151d1efad60fd9e021fb45fd3a" - integrity sha512-/ci/XgZG8jkLYOgOe3mpJY1onxPPTDY17y7scldhnSjjZqV6VvREG/LvwhRuV7BJbnENFfuDWZkSqlTh4x9ZjQ== + version "1.3.161" + resolved "https://registry.yarnpkg.com/electron-to-chromium/-/electron-to-chromium-1.3.161.tgz#48cb3de7a53d07c1ce654e8bc6e3f6b602f1ee3c" + integrity sha512-i8cuS1zf7TW2t/NrfiaF8amTggCH4yLRe7Pirdf6gVDESP146jXO9NXttM8bJk1aupwA1NVMoaikBSbnTHgZGA== emoji-regex@^7.0.1: version "7.0.3" @@ -2792,9 +2809,9 @@ jest-get-type@^24.8.0: integrity sha512-RR4fo8jEmMD9zSz2nLbs2j0zvPpk/KCEz3a62jJWbd2ayNo0cb+KFRxPHVhE4ZmgGJEQp0fosmNz84IfqM8cMQ== jest-haste-map@^24.8.0: - version "24.8.0" - resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.8.0.tgz#51794182d877b3ddfd6e6d23920e3fe72f305800" - integrity sha512-ZBPRGHdPt1rHajWelXdqygIDpJx8u3xOoLyUBWRW28r3tagrgoepPrzAozW7kW9HrQfhvmiv1tncsxqHJO1onQ== + version "24.8.1" + resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-24.8.1.tgz#f39cc1d2b1d907e014165b4bd5a957afcb992982" + integrity sha512-SwaxMGVdAZk3ernAx2Uv2sorA7jm3Kx+lR0grp6rMmnY06Kn/urtKx1LPN2mGTea4fCT38impYT28FfcLUhX0g== dependencies: "@jest/types" "^24.8.0" anymatch "^2.0.0" @@ -3233,10 +3250,10 @@ locate-path@^3.0.0: p-locate "^3.0.0" path-exists "^3.0.0" -lodash.merge@^4.6.0: +lodash.mergewith@^4.6.0: version "4.6.1" - resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.1.tgz#adc25d9cb99b9391c59624f379fbba60d7111d54" - integrity sha512-AOYza4+Hf5z1/0Hztxpm2/xiPZgi/cjMqdnKTUWTBSKchJlxXXuUSxCCl8rJlf4g6yww/j6mA8nC8Hw/EZWxKQ== + resolved "https://registry.yarnpkg.com/lodash.mergewith/-/lodash.mergewith-4.6.1.tgz#639057e726c3afbdb3e7d42741caa8d6e4335927" + integrity sha512-eWw5r+PYICtEBgrBE5hhlT6aAa75f411bgDz/ZL2KZqYV03USvucsxcHUIlGTDTECs1eunpI7HOV7U+WLDvNdQ== lodash.sortby@^4.7.0: version "4.7.0" @@ -4215,10 +4232,10 @@ resolve@1.1.7: resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.1.7.tgz#203114d82ad2c5ed9e8e0411b3932875e889e97b" integrity sha1-IDEU2CrSxe2ejgQRs5ModeiJ6Xs= -resolve@1.x, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.3.2, resolve@^1.5.0: - version "1.11.1" - resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.1.tgz#ea10d8110376982fef578df8fc30b9ac30a07a3e" - integrity sha512-vIpgF6wfuJOZI7KKKSP+HmiKggadPQAdsp5HiC1mvqnfp0gF1vdwgBWZIdrVft9pgqoMFQN+R7BSWZiBxx+BBw== +resolve@1.x, resolve@^1.10.0, resolve@^1.11.0, resolve@^1.3.2, resolve@^1.5.0, resolve@^1.8.1: + version "1.11.0" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.11.0.tgz#4014870ba296176b86343d50b60f3b50609ce232" + integrity sha512-WL2pBDjqT6pGUNSUzMw00o4T7If+z4H2x3Gz893WoUQ5KW8Vr9txp00ykiP16VBaZF5+j/OcXJHZ9+PCvdiDKw== dependencies: path-parse "^1.0.6" @@ -4303,7 +4320,7 @@ sax@^1.2.4: resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.0.tgz#790a7cf6fea5459bac96110b29b60412dc8ff96b" integrity sha512-Ya52jSX2u7QKghxeoFGpLwCtGlt7j0oY9DYb5apt9nPlJ42ID+ulTXESnt/qAQcoSERyZ5sl3LDIOw0nAn/5DA== -semver@^6.0.0, semver@^6.1.0: +semver@^6.0.0, semver@^6.1.1: version "6.1.1" resolved "https://registry.yarnpkg.com/semver/-/semver-6.1.1.tgz#53f53da9b30b2103cd4f15eab3a18ecbcb210c9b" integrity sha512-rWYq2e5iYW+fFe/oPPtYJxYgjBm8sC4rmoGdUOgBB7VnwKt6HrL793l2voH1UlsyYZpJ4g0wfjnTEO1s1NP2eQ== @@ -4606,9 +4623,9 @@ supports-color@^6.1.0: has-flag "^3.0.0" symbol-tree@^3.2.2: - version "3.2.2" - resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.2.tgz#ae27db38f660a7ae2e1c3b7d1bc290819b8519e6" - integrity sha1-rifbOPZgp64uHDt9G8KQgZuFGeY= + version "3.2.4" + resolved "https://registry.yarnpkg.com/symbol-tree/-/symbol-tree-3.2.4.tgz#430637d248ba77e078883951fb9aa0eed7c63fa2" + integrity sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw== table@^5.2.3: version "5.4.0" @@ -4744,9 +4761,9 @@ ts-jest@^24.0.2: yargs-parser "10.x" tslib@^1.9.0: - version "1.9.3" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" - integrity sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ== + version "1.10.0" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" + integrity sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ== tunnel-agent@^0.6.0: version "0.6.0"