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 1.13.1 to 1.14.0

3

lib/tokenize/expressions/array-pattern.js
'use strict';
const {entries} = Object;
const isForOf = ({parentPath}) => parentPath.parentPath.parentPath.isForOfStatement();

@@ -18,3 +17,3 @@

for (const [index, element] of entries(elements)) {
for (const [index, element] of elements.entries()) {
maybe.indent(isNewLine);

@@ -21,0 +20,0 @@ print(element);

@@ -8,4 +8,2 @@ 'use strict';

const {entries} = Object;
const CallExpression = {

@@ -32,3 +30,3 @@ beforeIf(path) {

for (const [i, arg] of entries(args)) {
for (const [i, arg] of args.entries()) {
if (isParentCall) {

@@ -35,0 +33,0 @@ print.newline();

'use strict';
const {entries} = Object;
module.exports.ClassDeclaration = (path, {maybe, print, indent}) => {

@@ -24,3 +22,3 @@ indent();

for (const [i, item] of entries(body)) {
for (const [i, item] of body.entries()) {
indent();

@@ -27,0 +25,0 @@ print(item);

'use strict';
const {entries} = Object;
module.exports.SequenceExpression = (path, {maybe, print}) => {

@@ -9,3 +7,3 @@ const expressions = path.get('expressions');

for (const [index, expression] of entries(expressions)) {
for (const [index, expression] of expressions.entries()) {
print(expression);

@@ -12,0 +10,0 @@ maybe.print(index < n, ',');

@@ -26,4 +26,5 @@ 'use strict';

},
Identifier(path, {write}) {
Identifier(path, {write, print}) {
write(path.node.name);
print('__typeAnnotation');
},

@@ -30,0 +31,0 @@ RegExpLiteral(path, {print}) {

'use strict';
const {entries} = Object;
module.exports.SwitchStatement = (path, {print, maybe}) => {

@@ -16,3 +14,3 @@ print('switch');

for (const [index, switchCase] of entries(cases)) {
for (const [index, switchCase] of cases.entries()) {
print('case');

@@ -19,0 +17,0 @@ print.space();

@@ -17,5 +17,13 @@ 'use strict';

},
TSTypeParameter(path, {print}) {
print(path.node.name);
TSTypeParameter(path, {write}) {
write(path.node.name);
},
TSNumberKeyword(path, {write}) {
write('number');
},
TSTypeAnnotation(path, {print}) {
print(':');
print.space();
print('__typeAnnotation');
},
TSExpressionWithTypeArguments(path, {print}) {

@@ -22,0 +30,0 @@ print('__expression');

{
"name": "@putout/printer",
"version": "1.13.1",
"version": "1.14.0",
"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