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

babel-generator

Package Overview
Dependencies
Maintainers
6
Versions
94
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-generator - npm Package Compare versions

Comparing version 6.3.18 to 6.3.19

8

lib/generators/expressions.js

@@ -211,5 +211,9 @@ /* @flow */

// http://javascript.spec.whatwg.org/#comment-syntax
spaces = node.operator === "<" && t.isUnaryExpression(node.right, { prefix: true, operator: "!" }) && t.isUnaryExpression(node.right.argument, { prefix: true, operator: "--" }) ||
spaces = node.operator === "<" && t.isUnaryExpression(node.right, { prefix: true, operator: "!" }) && t.isUnaryExpression(node.right.argument, { prefix: true, operator: "--" });
// Need spaces for operators of the same kind to avoid: `a+++b`
t.isUnaryExpression(node.right, { prefix: true, operator: node.operator }) || t.isUpdateExpression(node.right, { prefix: true, operator: node.operator + node.operator }) || t.isBinaryExpression(node.right) && t.isUnaryExpression(getLeftMost(node.right), { prefix: true, operator: node.operator });
if (!spaces) {
var right = getLeftMost(node.right);
spaces = t.isUnaryExpression(right, { prefix: true, operator: node.operator }) || t.isUpdateExpression(right, { prefix: true, operator: node.operator + node.operator });
}
}

@@ -216,0 +220,0 @@

{
"name": "babel-generator",
"version": "6.3.18",
"version": "6.3.19",
"description": "Turns an AST into code.",

@@ -5,0 +5,0 @@ "author": "Sebastian McKenzie <sebmck@gmail.com>",

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