@putout/printer 7.1.0 → 7.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/ChangeLog CHANGED
@@ -1,3 +1,14 @@
1
+ 2023.12.12, v7.1.2
2
+
3
+ feature:
4
+ - 7801ff7 @putout/printer: @putout/plugin-promises v14.0.0
5
+ - a34da40 @putout/printer: estree-to-babel v9.0.0
6
+
7
+ 2023.12.12, v7.1.1
8
+
9
+ feature:
10
+ - feefbe7 @putout/printer: rm useless comment deduplicate
11
+
1
12
  2023.12.11, v7.1.0
2
13
 
3
14
  fix:
package/README.md CHANGED
@@ -132,7 +132,7 @@ const overrides = {
132
132
  ```
133
133
 
134
134
  - `indent` - use two spaces, tabs, or anything you want;
135
- - `newline` - symbol for used for line separation;
135
+ - `newline` - symbol used for line separation;
136
136
  - `space` - default symbol used for space character;
137
137
  - `splitter` - mandatory symbol that used inside of statements like this:
138
138
  - `roundBraceOpen` and `roundBraceClose` symbols to output braces in a single argument arrow function expressions: `(a) => {}`.
@@ -10,8 +10,6 @@ const {
10
10
  const {markBefore} = require('../mark');
11
11
  const {maybeInsideFn} = require('./maybe-inside-fn');
12
12
 
13
- const deduplicate = (a) => Array.from(new Set(a));
14
-
15
13
  const {
16
14
  isObjectProperty,
17
15
  isVariableDeclarator,
@@ -74,7 +72,7 @@ module.exports.parseLeadingComments = (path, {print, maybe, indent}, semantics)
74
72
  const propIs = isProperty(path);
75
73
  const isIndent = isFirst(path) || !looksLikeSwitchCase && !path.isClassMethod() && !insideFn && !propIs;
76
74
 
77
- for (const {type, value} of deduplicate(leadingComments)) {
75
+ for (const {type, value} of leadingComments) {
78
76
  maybe.indent(isIndent);
79
77
 
80
78
  if (type === 'CommentLine') {
@@ -233,7 +233,6 @@ module.exports.tokenize = (ast, overrides) => {
233
233
 
234
234
  const currentIndent = i;
235
235
  parseLeadingComments(path, printer, semantics);
236
-
237
236
  // this is main thing
238
237
  maybePlugin(currentTraverse, path, printer, semantics);
239
238
  parseTrailingComments(path, printer, semantics);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@putout/printer",
3
- "version": "7.1.0",
3
+ "version": "7.1.2",
4
4
  "type": "commonjs",
5
5
  "author": "coderaiser <mnemonic.enemy@gmail.com> (https://github.com/coderaiser)",
6
6
  "description": "Simplest possible opinionated Babel AST printer for 🐊Putout",
@@ -48,7 +48,7 @@
48
48
  "@babel/plugin-codemod-object-assign-to-object-spread": "^7.10.4",
49
49
  "@putout/plugin-minify": "^6.2.0",
50
50
  "@putout/plugin-printer": "^3.0.0",
51
- "@putout/plugin-promises": "^13.0.0",
51
+ "@putout/plugin-promises": "^14.0.0",
52
52
  "@putout/plugin-react-hook-form": "^4.0.0",
53
53
  "@putout/plugin-react-hooks": "^5.0.0",
54
54
  "acorn": "^8.8.2",
@@ -58,7 +58,7 @@
58
58
  "eslint": "^8.0.1",
59
59
  "eslint-plugin-n": "^16.0.0",
60
60
  "eslint-plugin-putout": "^22.0.0",
61
- "estree-to-babel": "^8.0.0",
61
+ "estree-to-babel": "^9.0.0",
62
62
  "just-kebab-case": "^4.2.0",
63
63
  "madrun": "^10.0.0",
64
64
  "mock-require": "^3.0.3",