Socket
Socket
Sign inDemoInstall

@babel/plugin-transform-block-scoped-functions

Package Overview
Dependencies
Maintainers
4
Versions
70
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/plugin-transform-block-scoped-functions - npm Package Compare versions

Comparing version 7.18.6 to 7.21.4-esm

lib/index.js.map

14

lib/index.js

@@ -7,10 +7,6 @@ "use strict";

exports.default = void 0;
var _helperPluginUtils = require("@babel/helper-plugin-utils");
var _core = require("@babel/core");
var _default = (0, _helperPluginUtils.declare)(api => {
api.assertVersion(7);
function transformStatementList(paths) {

@@ -20,5 +16,3 @@ for (const path of paths) {

const func = path.node;
const declar = _core.types.variableDeclaration("let", [_core.types.variableDeclarator(func.id, _core.types.toExpression(func))]);
declar._blockHoist = 2;

@@ -29,3 +23,2 @@ func.id = null;

}
return {

@@ -39,3 +32,2 @@ name: "transform-block-scoped-functions",

} = path;
if (_core.types.isFunction(parent, {

@@ -46,14 +38,12 @@ body: node

}
transformStatementList(path.get("body"));
},
SwitchCase(path) {
transformStatementList(path.get("consequent"));
}
}
};
});
exports.default = _default;
exports.default = _default;
//# sourceMappingURL=index.js.map
{
"name": "@babel/plugin-transform-block-scoped-functions",
"version": "7.18.6",
"version": "7.21.4-esm",
"description": "Babel plugin to ensure function declarations at the block level are block scoped",

@@ -20,10 +20,10 @@ "repository": {

"dependencies": {
"@babel/helper-plugin-utils": "^7.18.6"
"@babel/helper-plugin-utils": "^7.21.4-esm"
},
"peerDependencies": {
"@babel/core": "^7.0.0-0"
"@babel/core": "^7.0.0-0 || 7.21.4-esm"
},
"devDependencies": {
"@babel/core": "^7.18.6",
"@babel/helper-plugin-test-runner": "^7.18.6"
"@babel/core": "^7.21.4-esm",
"@babel/helper-plugin-test-runner": "^7.21.4-esm"
},

@@ -30,0 +30,0 @@ "engines": {

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