From 81ddf9b700bc48a1f8e472209f080f9c1d9a9b09 Mon Sep 17 00:00:00 2001 From: Piotr Russ Date: Wed, 18 Nov 2020 23:26:45 +0100 Subject: rm node_modules --- .../lib/index.js | 63 ---------------------- 1 file changed, 63 deletions(-) delete mode 100644 node_modules/babel-plugin-transform-es2015-block-scoped-functions/lib/index.js (limited to 'node_modules/babel-plugin-transform-es2015-block-scoped-functions/lib/index.js') diff --git a/node_modules/babel-plugin-transform-es2015-block-scoped-functions/lib/index.js b/node_modules/babel-plugin-transform-es2015-block-scoped-functions/lib/index.js deleted file mode 100644 index f18cfc3..0000000 --- a/node_modules/babel-plugin-transform-es2015-block-scoped-functions/lib/index.js +++ /dev/null @@ -1,63 +0,0 @@ -"use strict"; - -exports.__esModule = true; - -var _getIterator2 = require("babel-runtime/core-js/get-iterator"); - -var _getIterator3 = _interopRequireDefault(_getIterator2); - -exports.default = function (_ref) { - var t = _ref.types; - - function statementList(key, path) { - var paths = path.get(key); - - for (var _iterator = paths, _isArray = Array.isArray(_iterator), _i = 0, _iterator = _isArray ? _iterator : (0, _getIterator3.default)(_iterator);;) { - var _ref2; - - if (_isArray) { - if (_i >= _iterator.length) break; - _ref2 = _iterator[_i++]; - } else { - _i = _iterator.next(); - if (_i.done) break; - _ref2 = _i.value; - } - - var _path = _ref2; - - var func = _path.node; - if (!_path.isFunctionDeclaration()) continue; - - var declar = t.variableDeclaration("let", [t.variableDeclarator(func.id, t.toExpression(func))]); - - declar._blockHoist = 2; - - func.id = null; - - _path.replaceWith(declar); - } - } - - return { - visitor: { - BlockStatement: function BlockStatement(path) { - var node = path.node, - parent = path.parent; - - if (t.isFunction(parent, { body: node }) || t.isExportDeclaration(parent)) { - return; - } - - statementList("body", path); - }, - SwitchCase: function SwitchCase(path) { - statementList("consequent", path); - } - } - }; -}; - -function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } - -module.exports = exports["default"]; \ No newline at end of file -- cgit v1.2.3