flatlint 1.77.0 → 1.79.0

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,13 @@
1
+ 2025.01.22, v1.79.0
2
+
3
+ feature:
4
+ - 3af1666 flatlint: convert-comma-to-semicolon: exclude: openCurlyBrace
5
+
6
+ 2025.01.22, v1.78.0
7
+
8
+ feature:
9
+ - fd9ced0 flatlint: convert-comma-to-semicolon: exclude quote
10
+
1
11
  2025.01.22, v1.77.0
2
12
 
3
13
  feature:
@@ -6,6 +6,7 @@ import {
6
6
  isOneOfKeywords,
7
7
  isOneOfPunctuators,
8
8
  isPunctuator,
9
+ openCurlyBrace,
9
10
  openRoundBrace,
10
11
  openSquireBrace,
11
12
  quote,
@@ -38,6 +39,7 @@ export const match = () => ({
38
39
 
39
40
  return !path.isNextPunctuator(quote);
40
41
  },
42
+ '__a.__b = __expr,': ({}, path) => !path.isNextPunctuator([quote, openCurlyBrace]),
41
43
  });
42
44
 
43
45
  export const replace = () => ({
@@ -47,10 +49,9 @@ export const replace = () => ({
47
49
  '__a(__args),': '__a(__args);',
48
50
  'return __expr,': 'return __expr;',
49
51
  '__a.__b = __expr,': '__a.__b = __expr;',
50
- '__a.__b.__c = __expr,': '__a.__b.__c = __expr;',
51
52
  });
52
53
 
53
- const check = ({__x, __a}, path) => {
54
+ const check = ({__x}, path) => {
54
55
  if (!isOneOfKeywords(__x, ['var', 'let', 'const']))
55
56
  return false;
56
57
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "flatlint",
3
- "version": "1.77.0",
3
+ "version": "1.79.0",
4
4
  "description": "JavaScript tokens-based linter",
5
5
  "main": "lib/flatlint.js",
6
6
  "type": "module",