flatlint 3.11.0 → 3.12.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
package/README.md
CHANGED
|
@@ -348,6 +348,18 @@ const a = class {
|
|
|
348
348
|
|
|
349
349
|
</details>
|
|
350
350
|
|
|
351
|
+
<details><summary>add missing <code>if</code></summary>
|
|
352
|
+
|
|
353
|
+
```diff
|
|
354
|
+
if (a < 0)
|
|
355
|
+
console.log('hello');
|
|
356
|
+
- else (a > 3)
|
|
357
|
+
+ else if (a > 3)
|
|
358
|
+
console.log('world');
|
|
359
|
+
```
|
|
360
|
+
|
|
361
|
+
</details>
|
|
362
|
+
|
|
351
363
|
## Template literals
|
|
352
364
|
|
|
353
365
|
**FlatLint** uses language similar to 🐊[**PutoutScript**](https://github.com/coderaiser/putout/blob/master/docs/putout-script.md#-putoutscript).
|
package/lib/plugins.js
CHANGED
|
@@ -6,6 +6,7 @@ import * as addMissingSquireBrace from './plugins/add-missing-square-brace/index
|
|
|
6
6
|
import * as addMissingQuote from './plugins/add-missing-quote/index.js';
|
|
7
7
|
import * as addMissingSemicolon from './plugins/add-missing-semicolon/index.js';
|
|
8
8
|
import * as addMissingComma from './plugins/add-missing-comma/index.js';
|
|
9
|
+
import * as addMissingIf from './plugins/add-missing-if/index.js';
|
|
9
10
|
import * as addConstToExport from './plugins/add-const-to-export/index.js';
|
|
10
11
|
import * as applyImportOrder from './plugins/apply-import-order/index.js';
|
|
11
12
|
import * as applyImportFrom from './plugins/apply-import-from/index.js';
|
|
@@ -26,6 +27,7 @@ import * as wrapAssignmentInParens from './plugins/wrap-assignment-in-parens/ind
|
|
|
26
27
|
|
|
27
28
|
export const plugins = [
|
|
28
29
|
['add-missing-comma', addMissingComma],
|
|
30
|
+
['add-missing-if', addMissingIf],
|
|
29
31
|
['add-missing-quote', addMissingQuote],
|
|
30
32
|
['add-const-to-export', addConstToExport],
|
|
31
33
|
['add-missing-semicolon', addMissingSemicolon],
|