Updated the files.
This commit is contained in:
parent
1553e6b971
commit
753967d4f5
23418 changed files with 3784666 additions and 0 deletions
22
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/LICENSE
generated
vendored
Executable file
22
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/LICENSE
generated
vendored
Executable file
|
@ -0,0 +1,22 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2014-present Sebastian McKenzie and other contributors
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining
|
||||
a copy of this software and associated documentation files (the
|
||||
"Software"), to deal in the Software without restriction, including
|
||||
without limitation the rights to use, copy, modify, merge, publish,
|
||||
distribute, sublicense, and/or sell copies of the Software, and to
|
||||
permit persons to whom the Software is furnished to do so, subject to
|
||||
the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
||||
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
||||
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
||||
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
||||
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
19
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/README.md
generated
vendored
Executable file
19
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/README.md
generated
vendored
Executable file
|
@ -0,0 +1,19 @@
|
|||
# @babel/plugin-transform-block-scoped-functions
|
||||
|
||||
> Babel plugin to ensure function declarations at the block level are block scoped
|
||||
|
||||
See our website [@babel/plugin-transform-block-scoped-functions](https://babeljs.io/docs/babel-plugin-transform-block-scoped-functions) for more information.
|
||||
|
||||
## Install
|
||||
|
||||
Using npm:
|
||||
|
||||
```sh
|
||||
npm install --save-dev @babel/plugin-transform-block-scoped-functions
|
||||
```
|
||||
|
||||
or using yarn:
|
||||
|
||||
```sh
|
||||
yarn add @babel/plugin-transform-block-scoped-functions --dev
|
||||
```
|
43
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/lib/index.js
generated
vendored
Executable file
43
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/lib/index.js
generated
vendored
Executable file
|
@ -0,0 +1,43 @@
|
|||
"use strict";
|
||||
|
||||
Object.defineProperty(exports, "__esModule", {
|
||||
value: true
|
||||
});
|
||||
exports.default = void 0;
|
||||
var _helperPluginUtils = require("@babel/helper-plugin-utils");
|
||||
var _core = require("@babel/core");
|
||||
var _default = exports.default = (0, _helperPluginUtils.declare)(api => {
|
||||
api.assertVersion(7);
|
||||
function transformStatementList(paths) {
|
||||
for (const path of paths) {
|
||||
if (!path.isFunctionDeclaration()) continue;
|
||||
const func = path.node;
|
||||
const declar = _core.types.variableDeclaration("let", [_core.types.variableDeclarator(func.id, _core.types.toExpression(func))]);
|
||||
declar._blockHoist = 2;
|
||||
func.id = null;
|
||||
path.replaceWith(declar);
|
||||
}
|
||||
}
|
||||
return {
|
||||
name: "transform-block-scoped-functions",
|
||||
visitor: {
|
||||
BlockStatement(path) {
|
||||
const {
|
||||
node,
|
||||
parent
|
||||
} = path;
|
||||
if (_core.types.isFunction(parent, {
|
||||
body: node
|
||||
}) || _core.types.isExportDeclaration(parent)) {
|
||||
return;
|
||||
}
|
||||
transformStatementList(path.get("body"));
|
||||
},
|
||||
SwitchCase(path) {
|
||||
transformStatementList(path.get("consequent"));
|
||||
}
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
//# sourceMappingURL=index.js.map
|
1
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/lib/index.js.map
generated
vendored
Executable file
1
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/lib/index.js.map
generated
vendored
Executable file
|
@ -0,0 +1 @@
|
|||
{"version":3,"names":["_helperPluginUtils","require","_core","_default","exports","default","declare","api","assertVersion","transformStatementList","paths","path","isFunctionDeclaration","func","node","declar","t","variableDeclaration","variableDeclarator","id","toExpression","_blockHoist","replaceWith","name","visitor","BlockStatement","parent","isFunction","body","isExportDeclaration","get","SwitchCase"],"sources":["../src/index.ts"],"sourcesContent":["import { declare } from \"@babel/helper-plugin-utils\";\nimport { types as t } from \"@babel/core\";\nimport type { NodePath } from \"@babel/traverse\";\n\nexport default declare(api => {\n api.assertVersion(\n process.env.BABEL_8_BREAKING && process.env.IS_PUBLISH\n ? PACKAGE_JSON.version\n : 7,\n );\n\n function transformStatementList(paths: NodePath<t.Statement>[]) {\n for (const path of paths) {\n if (!path.isFunctionDeclaration()) continue;\n const func = path.node;\n const declar = t.variableDeclaration(\"let\", [\n t.variableDeclarator(func.id, t.toExpression(func)),\n ]);\n\n // hoist it up above everything else\n // @ts-expect-error todo(flow->ts): avoid mutations\n declar._blockHoist = 2;\n\n // todo: name this\n func.id = null;\n\n path.replaceWith(declar);\n }\n }\n\n return {\n name: \"transform-block-scoped-functions\",\n\n visitor: {\n BlockStatement(path) {\n const { node, parent } = path;\n if (\n t.isFunction(parent, { body: node }) ||\n t.isExportDeclaration(parent)\n ) {\n return;\n }\n\n transformStatementList(path.get(\"body\"));\n },\n\n SwitchCase(path) {\n transformStatementList(path.get(\"consequent\"));\n },\n },\n };\n});\n"],"mappings":";;;;;;AAAA,IAAAA,kBAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAAyC,IAAAE,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAG1B,IAAAC,0BAAO,EAACC,GAAG,IAAI;EAC5BA,GAAG,CAACC,aAAa,CAGX,CACN,CAAC;EAED,SAASC,sBAAsBA,CAACC,KAA8B,EAAE;IAC9D,KAAK,MAAMC,IAAI,IAAID,KAAK,EAAE;MACxB,IAAI,CAACC,IAAI,CAACC,qBAAqB,CAAC,CAAC,EAAE;MACnC,MAAMC,IAAI,GAAGF,IAAI,CAACG,IAAI;MACtB,MAAMC,MAAM,GAAGC,WAAC,CAACC,mBAAmB,CAAC,KAAK,EAAE,CAC1CD,WAAC,CAACE,kBAAkB,CAACL,IAAI,CAACM,EAAE,EAAEH,WAAC,CAACI,YAAY,CAACP,IAAI,CAAC,CAAC,CACpD,CAAC;MAIFE,MAAM,CAACM,WAAW,GAAG,CAAC;MAGtBR,IAAI,CAACM,EAAE,GAAG,IAAI;MAEdR,IAAI,CAACW,WAAW,CAACP,MAAM,CAAC;IAC1B;EACF;EAEA,OAAO;IACLQ,IAAI,EAAE,kCAAkC;IAExCC,OAAO,EAAE;MACPC,cAAcA,CAACd,IAAI,EAAE;QACnB,MAAM;UAAEG,IAAI;UAAEY;QAAO,CAAC,GAAGf,IAAI;QAC7B,IACEK,WAAC,CAACW,UAAU,CAACD,MAAM,EAAE;UAAEE,IAAI,EAAEd;QAAK,CAAC,CAAC,IACpCE,WAAC,CAACa,mBAAmB,CAACH,MAAM,CAAC,EAC7B;UACA;QACF;QAEAjB,sBAAsB,CAACE,IAAI,CAACmB,GAAG,CAAC,MAAM,CAAC,CAAC;MAC1C,CAAC;MAEDC,UAAUA,CAACpB,IAAI,EAAE;QACfF,sBAAsB,CAACE,IAAI,CAACmB,GAAG,CAAC,YAAY,CAAC,CAAC;MAChD;IACF;EACF,CAAC;AACH,CAAC,CAAC"}
|
34
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/package.json
generated
vendored
Executable file
34
my-app/node_modules/@babel/plugin-transform-block-scoped-functions/package.json
generated
vendored
Executable file
|
@ -0,0 +1,34 @@
|
|||
{
|
||||
"name": "@babel/plugin-transform-block-scoped-functions",
|
||||
"version": "7.23.3",
|
||||
"description": "Babel plugin to ensure function declarations at the block level are block scoped",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/babel/babel.git",
|
||||
"directory": "packages/babel-plugin-transform-block-scoped-functions"
|
||||
},
|
||||
"homepage": "https://babel.dev/docs/en/next/babel-plugin-transform-block-scoped-functions",
|
||||
"license": "MIT",
|
||||
"publishConfig": {
|
||||
"access": "public"
|
||||
},
|
||||
"main": "./lib/index.js",
|
||||
"keywords": [
|
||||
"babel-plugin"
|
||||
],
|
||||
"dependencies": {
|
||||
"@babel/helper-plugin-utils": "^7.22.5"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@babel/core": "^7.0.0-0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@babel/core": "^7.23.3",
|
||||
"@babel/helper-plugin-test-runner": "^7.22.5"
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=6.9.0"
|
||||
},
|
||||
"author": "The Babel Team (https://babel.dev/team)",
|
||||
"type": "commonjs"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue