@babel/helper-wrap-function
Advanced tools
Comparing version 7.22.9 to 8.0.0-alpha.0
@@ -1,10 +0,5 @@ | ||
"use strict"; | ||
import nameFunction from '@babel/helper-function-name'; | ||
import template from '@babel/template'; | ||
import * as _t from '@babel/types'; | ||
Object.defineProperty(exports, "__esModule", { | ||
value: true | ||
}); | ||
exports.default = wrapFunction; | ||
var _helperFunctionName = require("@babel/helper-function-name"); | ||
var _template = require("@babel/template"); | ||
var _t = require("@babel/types"); | ||
const { | ||
@@ -20,3 +15,3 @@ blockStatement, | ||
} = _t; | ||
const buildAnonymousExpressionWrapper = _template.default.expression(` | ||
const buildAnonymousExpressionWrapper = template.expression(` | ||
(function () { | ||
@@ -29,3 +24,3 @@ var REF = FUNCTION; | ||
`); | ||
const buildNamedExpressionWrapper = _template.default.expression(` | ||
const buildNamedExpressionWrapper = template.expression(` | ||
(function () { | ||
@@ -39,3 +34,3 @@ var REF = FUNCTION; | ||
`); | ||
const buildDeclarationWrapper = _template.default.statements(` | ||
const buildDeclarationWrapper = template.statements(` | ||
function NAME(PARAMS) { return REF.apply(this, arguments); } | ||
@@ -63,6 +58,5 @@ function REF() { | ||
{ | ||
var _path$arrowFunctionTo; | ||
path = (_path$arrowFunctionTo = path.arrowFunctionToExpression({ | ||
path = path.arrowFunctionToExpression({ | ||
noNewArrows | ||
})) != null ? _path$arrowFunctionTo : path; | ||
}); | ||
} | ||
@@ -105,3 +99,3 @@ node = path.node; | ||
const returnFn = container.callee.body.body[1].argument; | ||
(0, _helperFunctionName.default)({ | ||
nameFunction({ | ||
node: returnFn, | ||
@@ -128,2 +122,3 @@ parent: path.parent, | ||
export { wrapFunction as default }; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@babel/helper-wrap-function", | ||
"version": "7.22.9", | ||
"version": "8.0.0-alpha.0", | ||
"description": "Helper to wrap functions inside a function call.", | ||
@@ -17,14 +17,18 @@ "repository": { | ||
"dependencies": { | ||
"@babel/helper-function-name": "^7.22.5", | ||
"@babel/template": "^7.22.5", | ||
"@babel/types": "^7.22.5" | ||
"@babel/helper-function-name": "^8.0.0-alpha.0", | ||
"@babel/template": "^8.0.0-alpha.0", | ||
"@babel/types": "^8.0.0-alpha.0" | ||
}, | ||
"engines": { | ||
"node": ">=6.9.0" | ||
"node": "^16.20.0 || ^18.16.0 || >=20.0.0" | ||
}, | ||
"devDependencies": { | ||
"@babel/traverse": "^7.22.8" | ||
"@babel/traverse": "^8.0.0-alpha.0" | ||
}, | ||
"author": "The Babel Team (https://babel.dev/team)", | ||
"type": "commonjs" | ||
"exports": { | ||
".": "./lib/index.js", | ||
"./package.json": "./package.json" | ||
}, | ||
"type": "module" | ||
} |
Sorry, the diff of this file is not supported yet
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
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
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
15588
Yes
116
1
+ Added@babel/code-frame@8.0.0-alpha.12(transitive)
+ Added@babel/helper-function-name@8.0.0-alpha.11(transitive)
+ Added@babel/helper-string-parser@8.0.0-alpha.12(transitive)
+ Added@babel/helper-validator-identifier@8.0.0-alpha.12(transitive)
+ Added@babel/highlight@8.0.0-alpha.12(transitive)
+ Added@babel/parser@8.0.0-alpha.12(transitive)
+ Added@babel/template@8.0.0-alpha.12(transitive)
+ Added@babel/types@8.0.0-alpha.12(transitive)
+ Addedjs-tokens@8.0.3(transitive)
+ Addedto-fast-properties@3.0.1(transitive)
- Removed@babel/code-frame@7.25.7(transitive)
- Removed@babel/helper-function-name@7.24.7(transitive)
- Removed@babel/helper-string-parser@7.25.7(transitive)
- Removed@babel/helper-validator-identifier@7.25.7(transitive)
- Removed@babel/highlight@7.25.7(transitive)
- Removed@babel/parser@7.25.7(transitive)
- Removed@babel/template@7.25.7(transitive)
- Removed@babel/types@7.25.7(transitive)
- Removedansi-styles@3.2.1(transitive)
- Removedchalk@2.4.2(transitive)
- Removedcolor-convert@1.9.3(transitive)
- Removedcolor-name@1.1.3(transitive)
- Removedescape-string-regexp@1.0.5(transitive)
- Removedhas-flag@3.0.0(transitive)
- Removedjs-tokens@4.0.0(transitive)
- Removedsupports-color@5.5.0(transitive)
- Removedto-fast-properties@2.0.0(transitive)
Updated@babel/types@^8.0.0-alpha.0