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

@putout/printer

Package Overview
Dependencies
Maintainers
1
Versions
599
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@putout/printer - npm Package Compare versions

Comparing version 8.20.0 to 8.20.1

21

lib/tokenize/expressions/array-expression/array-expression.js

@@ -39,2 +39,20 @@ 'use strict';

const isObjectAfterSimple = (a) => isObjectAfterSpread(a) || isObjectAfterIdentifier(a);
const isSpreadBeforeObject = (a) => {
if (!a.isObjectExpression())
return false;
const prev = a.getPrevSibling();
if (!prev.isSpreadElement())
return false;
if (prev.getPrevSibling().isObjectExpression())
return false;
return prev
.get('argument')
.isCallExpression();
};
const isNextSimple = (a) => {

@@ -119,3 +137,3 @@ const next = a.getNextSibling();

maybe.print.newline(is && !isNextObject(element));
maybe.print.newline((is || isSpreadBeforeObject(element)) && !isNextObject(element));
maybe.print.space(is && isObjectAfterSimple(element));

@@ -127,3 +145,2 @@

if (isNextSimpleBetweenObjects(element) || !(element.isObjectExpression() && isNextSimple(element)))
//if (!(element.isObjectExpression() && isNextSimple(element)))
print.space();

@@ -130,0 +147,0 @@ }

2

package.json
{
"name": "@putout/printer",
"version": "8.20.0",
"version": "8.20.1",
"type": "commonjs",

@@ -5,0 +5,0 @@ "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",

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