Socket
Socket
Sign inDemoInstall

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

Package Overview
Dependencies
Maintainers
6
Versions
108
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.13.8 to 7.13.10

23

lib/fields.js

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

if (file.availableHelper("writeOnlyError")) {
return _core.types.callExpression(file.addHelper("writeOnlyError"), [_core.types.stringLiteral(`#${name}`)]);
return _core.types.sequenceExpression([this.receiver(member), _core.types.callExpression(file.addHelper("writeOnlyError"), [_core.types.stringLiteral(`#${name}`)])]);
}

@@ -311,3 +311,3 @@

return _core.types.callExpression(file.addHelper("readOnlyError"), [_core.types.stringLiteral(`#${name}`)]);
return _core.types.sequenceExpression([this.receiver(member), value, _core.types.callExpression(file.addHelper("readOnlyError"), [_core.types.stringLiteral(`#${name}`)])]);
}

@@ -320,2 +320,3 @@

const {
classRef,
privateNamesMap,

@@ -328,4 +329,16 @@ file

const {
id
id,
static: isStatic
} = privateNamesMap.get(name);
if (isStatic) {
try {
var helper = file.addHelper("classStaticPrivateFieldDestructureSet");
} catch (_unused) {
throw new Error("Babel can not transpile `[C.#p] = [0]` with @babel/helpers < 7.13.10, \n" + "please update @babel/helpers to the latest version.");
}
return _core.types.memberExpression(_core.types.callExpression(helper, [this.receiver(member), _core.types.cloneNode(classRef), _core.types.cloneNode(id)]), _core.types.identifier("value"));
}
return _core.types.memberExpression(_core.types.callExpression(file.addHelper("classPrivateFieldDestructureSet"), [this.receiver(member), _core.types.cloneNode(id)]), _core.types.identifier("value"));

@@ -733,3 +746,3 @@ },

needsClassRef = true;
staticNodes.push(buildPrivateStaticFieldInitSpec(prop, privateNamesMap));
staticNodes.unshift(buildPrivateStaticFieldInitSpec(prop, privateNamesMap));
staticNodes.unshift(buildPrivateMethodDeclaration(prop, privateNamesMap, privateFieldsAsProperties));

@@ -740,3 +753,3 @@ break;

needsClassRef = true;
staticNodes.push(buildPrivateStaticMethodInitLoose(_core.types.cloneNode(ref), prop, state, privateNamesMap));
staticNodes.unshift(buildPrivateStaticMethodInitLoose(_core.types.cloneNode(ref), prop, state, privateNamesMap));
staticNodes.unshift(buildPrivateMethodDeclaration(prop, privateNamesMap, privateFieldsAsProperties));

@@ -743,0 +756,0 @@ break;

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

const version = "7.13.8".split(".").reduce((v, x) => v * 1e5 + +x, 0);
const version = "7.13.10".split(".").reduce((v, x) => v * 1e5 + +x, 0);
const versionKey = "@babel/plugin-class-features/version";

@@ -39,0 +39,0 @@

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

@@ -31,6 +31,6 @@ "license": "MIT",

"devDependencies": {
"@babel/core": "7.13.8",
"@babel/helper-plugin-test-runner": "7.12.13",
"@babel/preset-env": "7.13.8"
"@babel/core": "7.13.10",
"@babel/helper-plugin-test-runner": "7.13.10",
"@babel/preset-env": "7.13.10"
}
}
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