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

@babel/helper-member-expression-to-functions

Package Overview
Dependencies
Maintainers
6
Versions
80
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@babel/helper-member-expression-to-functions - npm Package Compare versions

Comparing version 7.10.5 to 7.11.0

19

lib/index.js

@@ -278,12 +278,19 @@ "use strict";

operator,
right
right: value
} = parent;
let value = right;
if (operator !== "=") {
this.memoise(member, 2);
value = t.binaryExpression(operator.slice(0, -1), this.get(member), value);
if (operator === "=") {
parentPath.replaceWith(this.set(member, value));
} else {
const operatorTrunc = operator.slice(0, -1);
if (t.LOGICAL_OPERATORS.includes(operatorTrunc)) {
this.memoise(member, 1);
parentPath.replaceWith(t.logicalExpression(operatorTrunc, this.get(member), this.set(member, value)));
} else {
this.memoise(member, 2);
parentPath.replaceWith(this.set(member, t.binaryExpression(operatorTrunc, this.get(member), value)));
}
}
parentPath.replaceWith(this.set(member, value));
return;

@@ -290,0 +297,0 @@ }

{
"name": "@babel/helper-member-expression-to-functions",
"version": "7.10.5",
"version": "7.11.0",
"description": "Helper function to replace certain member expressions with function calls",

@@ -17,5 +17,4 @@ "repository": {

"dependencies": {
"@babel/types": "^7.10.5"
},
"gitHead": "f7964a9ac51356f7df6404a25b27ba1cffba1ba7"
"@babel/types": "^7.11.0"
}
}
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