Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@babel/helper-create-class-features-plugin

Package Overview
Dependencies
Maintainers
4
Versions
110
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/helper-create-class-features-plugin - npm Package Compare versions

Comparing version 7.22.5 to 7.22.6

27

lib/fields.js

@@ -631,10 +631,14 @@ "use strict";

const thisContextVisitor = _core.traverse.visitors.merge([{
UnaryExpression(path) {
const {
node
} = path;
if (node.operator === "delete") {
const argument = (0, _helperSkipTransparentExpressionWrappers.skipTransparentExprWrapperNodes)(node.argument);
if (_core.types.isThisExpression(argument)) {
path.replaceWith(_core.types.booleanLiteral(true));
}
}
},
ThisExpression(path, state) {
const parent = path.findParent(path => !(0, _helperSkipTransparentExpressionWrappers.isTransparentExprWrapper)(path.node));
if (_core.types.isUnaryExpression(parent.node, {
operator: "delete"
})) {
path.parentPath.replaceWith(_core.types.booleanLiteral(true));
return;
}
state.needsClassRef = true;

@@ -644,12 +648,7 @@ path.replaceWith(_core.types.cloneNode(state.classRef));

MetaProperty(path) {
const meta = path.get("meta");
const property = path.get("property");
const {
node,
scope
} = path;
if (meta.isIdentifier({
name: "new"
}) && property.isIdentifier({
name: "target"
})) {
if (node.meta.name === "new" && node.property.name === "target") {
path.replaceWith(scope.buildUndefinedNode());

@@ -656,0 +655,0 @@ }

@@ -34,3 +34,3 @@ "use strict";

var _helperSplitExportDeclaration = require("@babel/helper-split-export-declaration");
var _semver = require("semver");
var _semverV = require("@nicolo-ribaudo/semver-v6");
var _fields = require("./fields");

@@ -88,8 +88,8 @@ var _decorators = require("./decorators");

if (typeof file.get(versionKey) === "number") {
file.set(versionKey, "7.22.5");
file.set(versionKey, "7.22.6");
return;
}
}
if (!file.get(versionKey) || _semver.lt(file.get(versionKey), "7.22.5")) {
file.set(versionKey, "7.22.5");
if (!file.get(versionKey) || _semverV.lt(file.get(versionKey), "7.22.6")) {
file.set(versionKey, "7.22.6");
}

@@ -101,3 +101,3 @@ },

}) {
if (file.get(versionKey) !== "7.22.5") return;
if (file.get(versionKey) !== "7.22.6") return;
if (!(0, _features.shouldTransform)(path, file)) return;

@@ -213,3 +213,3 @@ if (path.isClassDeclaration()) (0, _typescript.assertFieldTransformed)(path);

{
if (file.get(versionKey) !== "7.22.5") return;
if (file.get(versionKey) !== "7.22.6") return;
const decl = path.get("declaration");

@@ -216,0 +216,0 @@ if (decl.isClassDeclaration() && (0, _decorators.hasDecorators)(decl.node)) {

{
"name": "@babel/helper-create-class-features-plugin",
"version": "7.22.5",
"version": "7.22.6",
"author": "The Babel Team (https://babel.dev/team)",

@@ -28,4 +28,4 @@ "license": "MIT",

"@babel/helper-skip-transparent-expression-wrappers": "^7.22.5",
"@babel/helper-split-export-declaration": "^7.22.5",
"semver": "^6.3.0"
"@babel/helper-split-export-declaration": "^7.22.6",
"@nicolo-ribaudo/semver-v6": "^6.3.3"
},

@@ -36,6 +36,6 @@ "peerDependencies": {

"devDependencies": {
"@babel/core": "^7.22.5",
"@babel/core": "^7.22.6",
"@babel/helper-plugin-test-runner": "^7.22.5",
"@babel/plugin-syntax-class-static-block": "^7.14.5",
"@babel/preset-env": "^7.22.5"
"@babel/preset-env": "^7.22.6"
},

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

@@ -5,3 +5,3 @@ # @babel/helper-create-class-features-plugin

See our website [@babel/helper-create-class-features-plugin](https://babeljs.io/docs/en/babel-helper-create-class-features-plugin) for more information.
See our website [@babel/helper-create-class-features-plugin](https://babeljs.io/docs/babel-helper-create-class-features-plugin) for more information.

@@ -8,0 +8,0 @@ ## Install

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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