@gooddata/eslint-config 11.19.0-alpha.0 → 11.19.0-alpha.10

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.
Files changed (72) hide show
  1. package/LICENSE +7 -0
  2. package/PACKAGES_V8.md +26 -0
  3. package/PACKAGES_V9.md +28 -0
  4. package/PACKAGES_V9_OXLINT.md +28 -0
  5. package/README.md +135 -35
  6. package/dist/base.d.ts +12 -0
  7. package/dist/base.js +1869 -0
  8. package/dist/base.json +441 -98
  9. package/dist/browser-esm.d.ts +12 -0
  10. package/dist/browser-esm.js +1889 -0
  11. package/dist/browser-esm.json +442 -99
  12. package/dist/browser.d.ts +12 -0
  13. package/dist/browser.js +1874 -0
  14. package/dist/browser.json +441 -98
  15. package/dist/esm-react-cypress.d.ts +12 -0
  16. package/dist/esm-react-cypress.js +1991 -0
  17. package/dist/esm-react-cypress.json +454 -101
  18. package/dist/esm-react-vitest-storybook.d.ts +12 -0
  19. package/dist/esm-react-vitest-storybook.js +2013 -0
  20. package/dist/esm-react-vitest-storybook.json +480 -100
  21. package/dist/esm-react-vitest.d.ts +12 -0
  22. package/dist/esm-react-vitest.js +1979 -0
  23. package/dist/esm-react-vitest.json +463 -101
  24. package/dist/esm-react.d.ts +12 -0
  25. package/dist/esm-react.js +1935 -0
  26. package/dist/esm-react.json +440 -99
  27. package/dist/esm-vitest.d.ts +12 -0
  28. package/dist/esm-vitest.js +1928 -0
  29. package/dist/esm-vitest.json +465 -101
  30. package/dist/esm.d.ts +12 -0
  31. package/dist/esm.js +1884 -0
  32. package/dist/esm.json +442 -99
  33. package/dist/oxlint-base.d.ts +12 -0
  34. package/dist/oxlint-base.js +1869 -0
  35. package/dist/oxlint-browser-esm.d.ts +12 -0
  36. package/dist/oxlint-browser-esm.js +1889 -0
  37. package/dist/oxlint-browser.d.ts +12 -0
  38. package/dist/oxlint-browser.js +1874 -0
  39. package/dist/oxlint-esm-react-cypress.d.ts +12 -0
  40. package/dist/oxlint-esm-react-cypress.js +1991 -0
  41. package/dist/oxlint-esm-react-vitest-storybook.d.ts +12 -0
  42. package/dist/oxlint-esm-react-vitest-storybook.js +2013 -0
  43. package/dist/oxlint-esm-react-vitest.d.ts +12 -0
  44. package/dist/oxlint-esm-react-vitest.js +1979 -0
  45. package/dist/oxlint-esm-react.d.ts +12 -0
  46. package/dist/oxlint-esm-react.js +1935 -0
  47. package/dist/oxlint-esm-vitest.d.ts +12 -0
  48. package/dist/oxlint-esm-vitest.js +1928 -0
  49. package/dist/oxlint-esm.d.ts +12 -0
  50. package/dist/oxlint-esm.js +1884 -0
  51. package/dist/oxlint-react-cypress.d.ts +12 -0
  52. package/dist/oxlint-react-cypress.js +1982 -0
  53. package/dist/oxlint-react-vitest.d.ts +12 -0
  54. package/dist/oxlint-react-vitest.js +1970 -0
  55. package/dist/oxlint-react.d.ts +12 -0
  56. package/dist/oxlint-react.js +1926 -0
  57. package/dist/oxlint-vitest.d.ts +12 -0
  58. package/dist/oxlint-vitest.js +1913 -0
  59. package/dist/react-cypress.d.ts +12 -0
  60. package/dist/react-cypress.js +1982 -0
  61. package/dist/react-cypress.json +453 -100
  62. package/dist/react-vitest.d.ts +12 -0
  63. package/dist/react-vitest.js +1970 -0
  64. package/dist/react-vitest.json +462 -100
  65. package/dist/react.d.ts +12 -0
  66. package/dist/react.js +1926 -0
  67. package/dist/react.json +438 -97
  68. package/dist/vitest.d.ts +12 -0
  69. package/dist/vitest.js +1913 -0
  70. package/dist/vitest.json +464 -100
  71. package/package.json +122 -48
  72. package/dist/tsOverride.cjs +0 -23
package/dist/esm.js ADDED
@@ -0,0 +1,1884 @@
1
+ // This file is auto-generated. Do not edit manually.
2
+
3
+ import globals from "globals";
4
+ import plugin0001 from "eslint-plugin-headers";
5
+ import plugin0002 from "@typescript-eslint/eslint-plugin";
6
+ import plugin0003 from "@typescript-eslint/parser";
7
+ import plugin0004 from "eslint-plugin-no-barrel-files";
8
+ import plugin0005 from "eslint-plugin-import-x";
9
+ import plugin0006 from "eslint-plugin-jsdoc";
10
+ import plugin0007 from "eslint-plugin-sonarjs";
11
+ import plugin0008 from "eslint-plugin-import-esm";
12
+
13
+ export default [
14
+ {
15
+ languageOptions: {
16
+ globals: { ...globals.node, ...globals.es2022 },
17
+ },
18
+ },
19
+ {
20
+ rules: {
21
+ "constructor-super": "error",
22
+ "for-direction": "error",
23
+ "getter-return": "error",
24
+ "no-async-promise-executor": "error",
25
+ "no-case-declarations": "error",
26
+ "no-class-assign": "error",
27
+ "no-compare-neg-zero": "error",
28
+ "no-cond-assign": "error",
29
+ "no-const-assign": "error",
30
+ "no-constant-binary-expression": "error",
31
+ "no-constant-condition": "error",
32
+ "no-control-regex": "error",
33
+ "no-debugger": "error",
34
+ "no-delete-var": "error",
35
+ "no-dupe-args": "error",
36
+ "no-dupe-class-members": "error",
37
+ "no-dupe-else-if": "error",
38
+ "no-dupe-keys": "error",
39
+ "no-duplicate-case": "error",
40
+ "no-empty": "error",
41
+ "no-empty-character-class": "error",
42
+ "no-empty-pattern": "error",
43
+ "no-empty-static-block": "error",
44
+ "no-ex-assign": "error",
45
+ "no-fallthrough": "error",
46
+ "no-func-assign": "error",
47
+ "no-global-assign": "error",
48
+ "no-import-assign": "error",
49
+ "no-invalid-regexp": "error",
50
+ "no-irregular-whitespace": "error",
51
+ "no-loss-of-precision": "error",
52
+ "no-misleading-character-class": "error",
53
+ "no-new-native-nonconstructor": "error",
54
+ "no-nonoctal-decimal-escape": "error",
55
+ "no-obj-calls": "error",
56
+ "no-octal": "error",
57
+ "no-prototype-builtins": "error",
58
+ "no-redeclare": "error",
59
+ "no-regex-spaces": "error",
60
+ "no-self-assign": "error",
61
+ "no-setter-return": "error",
62
+ "no-shadow-restricted-names": "error",
63
+ "no-sparse-arrays": "error",
64
+ "no-this-before-super": "error",
65
+ "no-undef": "error",
66
+ "no-unreachable": "error",
67
+ "no-unsafe-finally": "error",
68
+ "no-unsafe-negation": "error",
69
+ "no-unsafe-optional-chaining": "error",
70
+ "no-unused-labels": "error",
71
+ "no-unused-private-class-members": "error",
72
+ "no-unused-vars": "error",
73
+ "no-useless-backreference": "error",
74
+ "no-useless-catch": "error",
75
+ "no-with": "error",
76
+ "require-yield": "error",
77
+ "use-isnan": "error",
78
+ "valid-typeof": "error",
79
+ "no-console": [
80
+ 2,
81
+ {
82
+ allow: [
83
+ "warn",
84
+ "error",
85
+ ],
86
+ },
87
+ ],
88
+ "no-restricted-exports": [
89
+ 2,
90
+ {
91
+ restrictDefaultExports: {
92
+ direct: true,
93
+ named: true,
94
+ defaultFrom: true,
95
+ namedFrom: true,
96
+ namespaceFrom: true,
97
+ },
98
+ },
99
+ ],
100
+ "no-duplicate-imports": [
101
+ "error",
102
+ {
103
+ includeExports: true,
104
+ },
105
+ ],
106
+ "no-restricted-imports": [
107
+ "error",
108
+ {
109
+ paths: [
110
+ {
111
+ name: "react",
112
+ importNames: [
113
+ "default",
114
+ ],
115
+ message: "Default import from React is not allowed. Use named imports instead.",
116
+ },
117
+ {
118
+ name: "react-dom",
119
+ importNames: [
120
+ "default",
121
+ ],
122
+ message: "Default import from React DOM is not allowed. Use named imports instead.",
123
+ },
124
+ {
125
+ name: "@gooddata/sdk-ui-kit",
126
+ importNames: [
127
+ "Icon",
128
+ ],
129
+ message: "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead.",
130
+ },
131
+ {
132
+ name: "vitest",
133
+ importNames: [
134
+ "test",
135
+ ],
136
+ message: "Use 'it' instead of 'test' for consistency.",
137
+ },
138
+ ],
139
+ patterns: [
140
+ {
141
+ group: [
142
+ "lodash-es",
143
+ ],
144
+ importNames: [
145
+ "get",
146
+ "getOr",
147
+ ],
148
+ message: "Please use the ?. and ?? operators instead.",
149
+ },
150
+ {
151
+ group: [
152
+ "lodash-es",
153
+ ],
154
+ importNames: [
155
+ "keys",
156
+ ],
157
+ message: "Please use Object.keys() instead.",
158
+ },
159
+ {
160
+ group: [
161
+ "lodash-es",
162
+ ],
163
+ importNames: [
164
+ "values",
165
+ ],
166
+ message: "Please use Object.values() instead.",
167
+ },
168
+ {
169
+ group: [
170
+ "lodash-es",
171
+ ],
172
+ importNames: [
173
+ "entries",
174
+ "toPairs",
175
+ ],
176
+ message: "Please use Object.entries() instead.",
177
+ },
178
+ {
179
+ group: [
180
+ "lodash-es",
181
+ ],
182
+ importNames: [
183
+ "map",
184
+ ],
185
+ message: "Please use Array.prototype.map() instead.",
186
+ },
187
+ {
188
+ group: [
189
+ "lodash-es",
190
+ ],
191
+ importNames: [
192
+ "flatMap",
193
+ ],
194
+ message: "Please use Array.prototype.flatMap() instead.",
195
+ },
196
+ {
197
+ group: [
198
+ "lodash-es",
199
+ ],
200
+ importNames: [
201
+ "filter",
202
+ ],
203
+ message: "Please use Array.prototype.filter() instead.",
204
+ },
205
+ {
206
+ group: [
207
+ "lodash-es",
208
+ ],
209
+ importNames: [
210
+ "find",
211
+ ],
212
+ message: "Please use Array.prototype.find() instead.",
213
+ },
214
+ {
215
+ group: [
216
+ "lodash-es",
217
+ ],
218
+ importNames: [
219
+ "findIndex",
220
+ ],
221
+ message: "Please use Array.prototype.findIndex() instead.",
222
+ },
223
+ {
224
+ group: [
225
+ "lodash-es",
226
+ ],
227
+ importNames: [
228
+ "includes",
229
+ ],
230
+ message: "Please use Array.prototype.includes() instead.",
231
+ },
232
+ {
233
+ group: [
234
+ "lodash-es",
235
+ ],
236
+ importNames: [
237
+ "some",
238
+ ],
239
+ message: "Please use Array.prototype.some() instead.",
240
+ },
241
+ {
242
+ group: [
243
+ "lodash-es",
244
+ ],
245
+ importNames: [
246
+ "every",
247
+ ],
248
+ message: "Please use Array.prototype.every() instead.",
249
+ },
250
+ {
251
+ group: [
252
+ "lodash-es",
253
+ ],
254
+ importNames: [
255
+ "concat",
256
+ ],
257
+ message: "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead.",
258
+ },
259
+ {
260
+ group: [
261
+ "lodash-es",
262
+ ],
263
+ importNames: [
264
+ "reverse",
265
+ ],
266
+ message: "Please use Array.prototype.reverse() instead.",
267
+ },
268
+ {
269
+ group: [
270
+ "lodash-es",
271
+ ],
272
+ importNames: [
273
+ "slice",
274
+ ],
275
+ message: "Please use Array.prototype.slice() instead.",
276
+ },
277
+ {
278
+ group: [
279
+ "lodash-es",
280
+ ],
281
+ importNames: [
282
+ "indexOf",
283
+ ],
284
+ message: "Please use Array.prototype.indexOf() instead.",
285
+ },
286
+ {
287
+ group: [
288
+ "lodash-es",
289
+ ],
290
+ importNames: [
291
+ "lastIndexOf",
292
+ ],
293
+ message: "Please use Array.prototype.lastIndexOf() instead.",
294
+ },
295
+ {
296
+ group: [
297
+ "lodash-es",
298
+ ],
299
+ importNames: [
300
+ "fill",
301
+ ],
302
+ message: "Please use Array.prototype.fill() instead.",
303
+ },
304
+ {
305
+ group: [
306
+ "lodash-es",
307
+ ],
308
+ importNames: [
309
+ "startsWith",
310
+ ],
311
+ message: "Please use String.prototype.startsWith() instead.",
312
+ },
313
+ {
314
+ group: [
315
+ "lodash-es",
316
+ ],
317
+ importNames: [
318
+ "endsWith",
319
+ ],
320
+ message: "Please use String.prototype.endsWith() instead.",
321
+ },
322
+ {
323
+ group: [
324
+ "lodash-es",
325
+ ],
326
+ importNames: [
327
+ "repeat",
328
+ ],
329
+ message: "Please use String.prototype.repeat() instead.",
330
+ },
331
+ {
332
+ group: [
333
+ "lodash-es",
334
+ ],
335
+ importNames: [
336
+ "padStart",
337
+ ],
338
+ message: "Please use String.prototype.padStart() instead.",
339
+ },
340
+ {
341
+ group: [
342
+ "lodash-es",
343
+ ],
344
+ importNames: [
345
+ "padEnd",
346
+ ],
347
+ message: "Please use String.prototype.padEnd() instead.",
348
+ },
349
+ {
350
+ group: [
351
+ "lodash-es",
352
+ ],
353
+ importNames: [
354
+ "trim",
355
+ ],
356
+ message: "Please use String.prototype.trim() instead.",
357
+ },
358
+ {
359
+ group: [
360
+ "lodash-es",
361
+ ],
362
+ importNames: [
363
+ "trimStart",
364
+ "trimLeft",
365
+ ],
366
+ message: "Please use String.prototype.trimStart() instead.",
367
+ },
368
+ {
369
+ group: [
370
+ "lodash-es",
371
+ ],
372
+ importNames: [
373
+ "trimEnd",
374
+ "trimRight",
375
+ ],
376
+ message: "Please use String.prototype.trimEnd() instead.",
377
+ },
378
+ {
379
+ group: [
380
+ "lodash-es",
381
+ ],
382
+ importNames: [
383
+ "toUpper",
384
+ ],
385
+ message: "Please use String.prototype.toUpperCase() instead.",
386
+ },
387
+ {
388
+ group: [
389
+ "lodash-es",
390
+ ],
391
+ importNames: [
392
+ "toLower",
393
+ ],
394
+ message: "Please use String.prototype.toLowerCase() instead.",
395
+ },
396
+ {
397
+ group: [
398
+ "lodash-es",
399
+ ],
400
+ importNames: [
401
+ "isArray",
402
+ ],
403
+ message: "Please use Array.isArray() instead.",
404
+ },
405
+ {
406
+ group: [
407
+ "lodash-es",
408
+ ],
409
+ importNames: [
410
+ "isNaN",
411
+ ],
412
+ message: "Please use Number.isNaN() instead.",
413
+ },
414
+ {
415
+ group: [
416
+ "lodash-es",
417
+ ],
418
+ importNames: [
419
+ "isFinite",
420
+ ],
421
+ message: "Please use Number.isFinite() instead.",
422
+ },
423
+ {
424
+ group: [
425
+ "lodash-es",
426
+ ],
427
+ importNames: [
428
+ "isInteger",
429
+ ],
430
+ message: "Please use Number.isInteger() instead.",
431
+ },
432
+ {
433
+ group: [
434
+ "lodash-es",
435
+ ],
436
+ importNames: [
437
+ "isNull",
438
+ ],
439
+ message: "Please use value === null instead.",
440
+ },
441
+ {
442
+ group: [
443
+ "lodash-es",
444
+ ],
445
+ importNames: [
446
+ "isUndefined",
447
+ ],
448
+ message: "Please use value === undefined instead.",
449
+ },
450
+ {
451
+ group: [
452
+ "lodash-es",
453
+ ],
454
+ importNames: [
455
+ "defaultTo",
456
+ ],
457
+ message: "Please use value ?? defaultValue instead.",
458
+ },
459
+ {
460
+ group: [
461
+ "lodash-es",
462
+ ],
463
+ importNames: [
464
+ "assign",
465
+ ],
466
+ message: "Please use Object.assign() or spread syntax {...obj} instead.",
467
+ },
468
+ {
469
+ group: [
470
+ "lodash-es",
471
+ ],
472
+ importNames: [
473
+ "flatten",
474
+ ],
475
+ message: "Please use Array.prototype.flat() instead.",
476
+ },
477
+ {
478
+ group: [
479
+ "lodash-es",
480
+ ],
481
+ importNames: [
482
+ "flattenDeep",
483
+ ],
484
+ message: "Please use Array.prototype.flat(Infinity) instead.",
485
+ },
486
+ {
487
+ group: [
488
+ "lodash-es",
489
+ ],
490
+ importNames: [
491
+ "isNil",
492
+ ],
493
+ message: "Please use value === null || value === undefined instead.",
494
+ },
495
+ {
496
+ group: [
497
+ "lodash-es",
498
+ ],
499
+ importNames: [
500
+ "noop",
501
+ ],
502
+ message: "Please use () => {} instead.",
503
+ },
504
+ {
505
+ group: [
506
+ "lodash-es",
507
+ ],
508
+ importNames: [
509
+ "identity",
510
+ ],
511
+ message: "Please use x => x instead.",
512
+ },
513
+ {
514
+ group: [
515
+ "lodash-es",
516
+ ],
517
+ importNames: [
518
+ "first",
519
+ "head",
520
+ ],
521
+ message: "Please use Array.prototype.at(0) instead.",
522
+ },
523
+ {
524
+ group: [
525
+ "lodash-es",
526
+ ],
527
+ importNames: [
528
+ "last",
529
+ ],
530
+ message: "Please use Array.prototype.at(-1) instead.",
531
+ },
532
+ {
533
+ group: [
534
+ "lodash-es",
535
+ ],
536
+ importNames: [
537
+ "forEach",
538
+ ],
539
+ message: "Please use Array.prototype.forEach() instead.",
540
+ },
541
+ {
542
+ group: [
543
+ "lodash-es",
544
+ ],
545
+ importNames: [
546
+ "fromPairs",
547
+ ],
548
+ message: "Please use Object.fromEntries() instead.",
549
+ },
550
+ {
551
+ group: [
552
+ "lodash-es",
553
+ ],
554
+ importNames: [
555
+ "join",
556
+ ],
557
+ message: "Please use Array.prototype.join() instead.",
558
+ },
559
+ {
560
+ group: [
561
+ "lodash-es",
562
+ ],
563
+ importNames: [
564
+ "isDate",
565
+ ],
566
+ message: "Please use val instanceof Date instead.",
567
+ },
568
+ {
569
+ group: [
570
+ "lodash-es",
571
+ ],
572
+ importNames: [
573
+ "isFunction",
574
+ ],
575
+ message: "Please use typeof val === 'function' instead.",
576
+ },
577
+ {
578
+ group: [
579
+ "lodash-es",
580
+ ],
581
+ importNames: [
582
+ "isNumber",
583
+ ],
584
+ message: "Please use typeof val === 'number' instead.",
585
+ },
586
+ {
587
+ group: [
588
+ "lodash-es",
589
+ ],
590
+ importNames: [
591
+ "isObject",
592
+ ],
593
+ message: "Please use val !== null && typeof val === 'object' instead.",
594
+ },
595
+ {
596
+ group: [
597
+ "lodash-es",
598
+ ],
599
+ importNames: [
600
+ "isString",
601
+ ],
602
+ message: "Please use typeof val === 'string' instead.",
603
+ },
604
+ {
605
+ group: [
606
+ "lodash-es",
607
+ ],
608
+ importNames: [
609
+ "toString",
610
+ ],
611
+ message: "Please use String(val) instead.",
612
+ },
613
+ {
614
+ group: [
615
+ "lodash-es",
616
+ ],
617
+ importNames: [
618
+ "flow",
619
+ "flowRight",
620
+ ],
621
+ message: "Please use refactoring your code instead.",
622
+ },
623
+ ],
624
+ },
625
+ ],
626
+ "no-restricted-syntax": [
627
+ "error",
628
+ {
629
+ selector: "MemberExpression[object.name='React']",
630
+ message: "Do not use `React.*`. Use named imports instead.",
631
+ },
632
+ {
633
+ selector: "MemberExpression[object.name='ReactDOM']",
634
+ message: "Do not use `ReactDOM.*`. Use named imports instead.",
635
+ },
636
+ ],
637
+ "sort-imports": [
638
+ "error",
639
+ {
640
+ ignoreCase: false,
641
+ ignoreDeclarationSort: true,
642
+ ignoreMemberSort: false,
643
+ },
644
+ ],
645
+ "no-useless-escape": "off",
646
+ "no-negated-condition": "error",
647
+ "no-unneeded-ternary": [
648
+ "error",
649
+ {
650
+ defaultAssignment: false,
651
+ },
652
+ ],
653
+ "no-extra-boolean-cast": "error",
654
+ "no-unexpected-multiline": "off",
655
+ },
656
+ },
657
+ {
658
+ files: [
659
+ "**/*.ts",
660
+ "**/*.tsx",
661
+ ],
662
+ ignores: [
663
+ "**/vitest.config.ts",
664
+ "**/vitest.*.config.ts",
665
+ "**/vitest.setup.ts",
666
+ "**/vitest.setup.tsx",
667
+ "**/*.test.ts",
668
+ "**/*.test.tsx",
669
+ "**/*.test.utils.ts",
670
+ "**/*.test.utils.tsx",
671
+ "**/*.test.helpers.ts",
672
+ "**/*.test.helpers.tsx",
673
+ ],
674
+ rules: {
675
+ "no-restricted-imports": [
676
+ "error",
677
+ {
678
+ paths: [
679
+ {
680
+ name: "react",
681
+ importNames: [
682
+ "default",
683
+ ],
684
+ message: "Default import from React is not allowed. Use named imports instead.",
685
+ },
686
+ {
687
+ name: "react-dom",
688
+ importNames: [
689
+ "default",
690
+ ],
691
+ message: "Default import from React DOM is not allowed. Use named imports instead.",
692
+ },
693
+ {
694
+ name: "@gooddata/sdk-ui-kit",
695
+ importNames: [
696
+ "Icon",
697
+ ],
698
+ message: "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead.",
699
+ },
700
+ {
701
+ name: "vitest",
702
+ importNames: [
703
+ "test",
704
+ ],
705
+ message: "Use 'it' instead of 'test' for consistency.",
706
+ },
707
+ ],
708
+ patterns: [
709
+ {
710
+ group: [
711
+ "lodash-es",
712
+ ],
713
+ importNames: [
714
+ "get",
715
+ "getOr",
716
+ ],
717
+ message: "Please use the ?. and ?? operators instead.",
718
+ },
719
+ {
720
+ group: [
721
+ "lodash-es",
722
+ ],
723
+ importNames: [
724
+ "keys",
725
+ ],
726
+ message: "Please use Object.keys() instead.",
727
+ },
728
+ {
729
+ group: [
730
+ "lodash-es",
731
+ ],
732
+ importNames: [
733
+ "values",
734
+ ],
735
+ message: "Please use Object.values() instead.",
736
+ },
737
+ {
738
+ group: [
739
+ "lodash-es",
740
+ ],
741
+ importNames: [
742
+ "entries",
743
+ "toPairs",
744
+ ],
745
+ message: "Please use Object.entries() instead.",
746
+ },
747
+ {
748
+ group: [
749
+ "lodash-es",
750
+ ],
751
+ importNames: [
752
+ "map",
753
+ ],
754
+ message: "Please use Array.prototype.map() instead.",
755
+ },
756
+ {
757
+ group: [
758
+ "lodash-es",
759
+ ],
760
+ importNames: [
761
+ "flatMap",
762
+ ],
763
+ message: "Please use Array.prototype.flatMap() instead.",
764
+ },
765
+ {
766
+ group: [
767
+ "lodash-es",
768
+ ],
769
+ importNames: [
770
+ "filter",
771
+ ],
772
+ message: "Please use Array.prototype.filter() instead.",
773
+ },
774
+ {
775
+ group: [
776
+ "lodash-es",
777
+ ],
778
+ importNames: [
779
+ "find",
780
+ ],
781
+ message: "Please use Array.prototype.find() instead.",
782
+ },
783
+ {
784
+ group: [
785
+ "lodash-es",
786
+ ],
787
+ importNames: [
788
+ "findIndex",
789
+ ],
790
+ message: "Please use Array.prototype.findIndex() instead.",
791
+ },
792
+ {
793
+ group: [
794
+ "lodash-es",
795
+ ],
796
+ importNames: [
797
+ "includes",
798
+ ],
799
+ message: "Please use Array.prototype.includes() instead.",
800
+ },
801
+ {
802
+ group: [
803
+ "lodash-es",
804
+ ],
805
+ importNames: [
806
+ "some",
807
+ ],
808
+ message: "Please use Array.prototype.some() instead.",
809
+ },
810
+ {
811
+ group: [
812
+ "lodash-es",
813
+ ],
814
+ importNames: [
815
+ "every",
816
+ ],
817
+ message: "Please use Array.prototype.every() instead.",
818
+ },
819
+ {
820
+ group: [
821
+ "lodash-es",
822
+ ],
823
+ importNames: [
824
+ "concat",
825
+ ],
826
+ message: "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead.",
827
+ },
828
+ {
829
+ group: [
830
+ "lodash-es",
831
+ ],
832
+ importNames: [
833
+ "reverse",
834
+ ],
835
+ message: "Please use Array.prototype.reverse() instead.",
836
+ },
837
+ {
838
+ group: [
839
+ "lodash-es",
840
+ ],
841
+ importNames: [
842
+ "slice",
843
+ ],
844
+ message: "Please use Array.prototype.slice() instead.",
845
+ },
846
+ {
847
+ group: [
848
+ "lodash-es",
849
+ ],
850
+ importNames: [
851
+ "indexOf",
852
+ ],
853
+ message: "Please use Array.prototype.indexOf() instead.",
854
+ },
855
+ {
856
+ group: [
857
+ "lodash-es",
858
+ ],
859
+ importNames: [
860
+ "lastIndexOf",
861
+ ],
862
+ message: "Please use Array.prototype.lastIndexOf() instead.",
863
+ },
864
+ {
865
+ group: [
866
+ "lodash-es",
867
+ ],
868
+ importNames: [
869
+ "fill",
870
+ ],
871
+ message: "Please use Array.prototype.fill() instead.",
872
+ },
873
+ {
874
+ group: [
875
+ "lodash-es",
876
+ ],
877
+ importNames: [
878
+ "startsWith",
879
+ ],
880
+ message: "Please use String.prototype.startsWith() instead.",
881
+ },
882
+ {
883
+ group: [
884
+ "lodash-es",
885
+ ],
886
+ importNames: [
887
+ "endsWith",
888
+ ],
889
+ message: "Please use String.prototype.endsWith() instead.",
890
+ },
891
+ {
892
+ group: [
893
+ "lodash-es",
894
+ ],
895
+ importNames: [
896
+ "repeat",
897
+ ],
898
+ message: "Please use String.prototype.repeat() instead.",
899
+ },
900
+ {
901
+ group: [
902
+ "lodash-es",
903
+ ],
904
+ importNames: [
905
+ "padStart",
906
+ ],
907
+ message: "Please use String.prototype.padStart() instead.",
908
+ },
909
+ {
910
+ group: [
911
+ "lodash-es",
912
+ ],
913
+ importNames: [
914
+ "padEnd",
915
+ ],
916
+ message: "Please use String.prototype.padEnd() instead.",
917
+ },
918
+ {
919
+ group: [
920
+ "lodash-es",
921
+ ],
922
+ importNames: [
923
+ "trim",
924
+ ],
925
+ message: "Please use String.prototype.trim() instead.",
926
+ },
927
+ {
928
+ group: [
929
+ "lodash-es",
930
+ ],
931
+ importNames: [
932
+ "trimStart",
933
+ "trimLeft",
934
+ ],
935
+ message: "Please use String.prototype.trimStart() instead.",
936
+ },
937
+ {
938
+ group: [
939
+ "lodash-es",
940
+ ],
941
+ importNames: [
942
+ "trimEnd",
943
+ "trimRight",
944
+ ],
945
+ message: "Please use String.prototype.trimEnd() instead.",
946
+ },
947
+ {
948
+ group: [
949
+ "lodash-es",
950
+ ],
951
+ importNames: [
952
+ "toUpper",
953
+ ],
954
+ message: "Please use String.prototype.toUpperCase() instead.",
955
+ },
956
+ {
957
+ group: [
958
+ "lodash-es",
959
+ ],
960
+ importNames: [
961
+ "toLower",
962
+ ],
963
+ message: "Please use String.prototype.toLowerCase() instead.",
964
+ },
965
+ {
966
+ group: [
967
+ "lodash-es",
968
+ ],
969
+ importNames: [
970
+ "isArray",
971
+ ],
972
+ message: "Please use Array.isArray() instead.",
973
+ },
974
+ {
975
+ group: [
976
+ "lodash-es",
977
+ ],
978
+ importNames: [
979
+ "isNaN",
980
+ ],
981
+ message: "Please use Number.isNaN() instead.",
982
+ },
983
+ {
984
+ group: [
985
+ "lodash-es",
986
+ ],
987
+ importNames: [
988
+ "isFinite",
989
+ ],
990
+ message: "Please use Number.isFinite() instead.",
991
+ },
992
+ {
993
+ group: [
994
+ "lodash-es",
995
+ ],
996
+ importNames: [
997
+ "isInteger",
998
+ ],
999
+ message: "Please use Number.isInteger() instead.",
1000
+ },
1001
+ {
1002
+ group: [
1003
+ "lodash-es",
1004
+ ],
1005
+ importNames: [
1006
+ "isNull",
1007
+ ],
1008
+ message: "Please use value === null instead.",
1009
+ },
1010
+ {
1011
+ group: [
1012
+ "lodash-es",
1013
+ ],
1014
+ importNames: [
1015
+ "isUndefined",
1016
+ ],
1017
+ message: "Please use value === undefined instead.",
1018
+ },
1019
+ {
1020
+ group: [
1021
+ "lodash-es",
1022
+ ],
1023
+ importNames: [
1024
+ "defaultTo",
1025
+ ],
1026
+ message: "Please use value ?? defaultValue instead.",
1027
+ },
1028
+ {
1029
+ group: [
1030
+ "lodash-es",
1031
+ ],
1032
+ importNames: [
1033
+ "assign",
1034
+ ],
1035
+ message: "Please use Object.assign() or spread syntax {...obj} instead.",
1036
+ },
1037
+ {
1038
+ group: [
1039
+ "lodash-es",
1040
+ ],
1041
+ importNames: [
1042
+ "flatten",
1043
+ ],
1044
+ message: "Please use Array.prototype.flat() instead.",
1045
+ },
1046
+ {
1047
+ group: [
1048
+ "lodash-es",
1049
+ ],
1050
+ importNames: [
1051
+ "flattenDeep",
1052
+ ],
1053
+ message: "Please use Array.prototype.flat(Infinity) instead.",
1054
+ },
1055
+ {
1056
+ group: [
1057
+ "lodash-es",
1058
+ ],
1059
+ importNames: [
1060
+ "isNil",
1061
+ ],
1062
+ message: "Please use value === null || value === undefined instead.",
1063
+ },
1064
+ {
1065
+ group: [
1066
+ "lodash-es",
1067
+ ],
1068
+ importNames: [
1069
+ "noop",
1070
+ ],
1071
+ message: "Please use () => {} instead.",
1072
+ },
1073
+ {
1074
+ group: [
1075
+ "lodash-es",
1076
+ ],
1077
+ importNames: [
1078
+ "identity",
1079
+ ],
1080
+ message: "Please use x => x instead.",
1081
+ },
1082
+ {
1083
+ group: [
1084
+ "lodash-es",
1085
+ ],
1086
+ importNames: [
1087
+ "first",
1088
+ "head",
1089
+ ],
1090
+ message: "Please use Array.prototype.at(0) instead.",
1091
+ },
1092
+ {
1093
+ group: [
1094
+ "lodash-es",
1095
+ ],
1096
+ importNames: [
1097
+ "last",
1098
+ ],
1099
+ message: "Please use Array.prototype.at(-1) instead.",
1100
+ },
1101
+ {
1102
+ group: [
1103
+ "lodash-es",
1104
+ ],
1105
+ importNames: [
1106
+ "forEach",
1107
+ ],
1108
+ message: "Please use Array.prototype.forEach() instead.",
1109
+ },
1110
+ {
1111
+ group: [
1112
+ "lodash-es",
1113
+ ],
1114
+ importNames: [
1115
+ "fromPairs",
1116
+ ],
1117
+ message: "Please use Object.fromEntries() instead.",
1118
+ },
1119
+ {
1120
+ group: [
1121
+ "lodash-es",
1122
+ ],
1123
+ importNames: [
1124
+ "join",
1125
+ ],
1126
+ message: "Please use Array.prototype.join() instead.",
1127
+ },
1128
+ {
1129
+ group: [
1130
+ "lodash-es",
1131
+ ],
1132
+ importNames: [
1133
+ "isDate",
1134
+ ],
1135
+ message: "Please use val instanceof Date instead.",
1136
+ },
1137
+ {
1138
+ group: [
1139
+ "lodash-es",
1140
+ ],
1141
+ importNames: [
1142
+ "isFunction",
1143
+ ],
1144
+ message: "Please use typeof val === 'function' instead.",
1145
+ },
1146
+ {
1147
+ group: [
1148
+ "lodash-es",
1149
+ ],
1150
+ importNames: [
1151
+ "isNumber",
1152
+ ],
1153
+ message: "Please use typeof val === 'number' instead.",
1154
+ },
1155
+ {
1156
+ group: [
1157
+ "lodash-es",
1158
+ ],
1159
+ importNames: [
1160
+ "isObject",
1161
+ ],
1162
+ message: "Please use val !== null && typeof val === 'object' instead.",
1163
+ },
1164
+ {
1165
+ group: [
1166
+ "lodash-es",
1167
+ ],
1168
+ importNames: [
1169
+ "isString",
1170
+ ],
1171
+ message: "Please use typeof val === 'string' instead.",
1172
+ },
1173
+ {
1174
+ group: [
1175
+ "lodash-es",
1176
+ ],
1177
+ importNames: [
1178
+ "toString",
1179
+ ],
1180
+ message: "Please use String(val) instead.",
1181
+ },
1182
+ {
1183
+ group: [
1184
+ "lodash-es",
1185
+ ],
1186
+ importNames: [
1187
+ "flow",
1188
+ "flowRight",
1189
+ ],
1190
+ message: "Please use refactoring your code instead.",
1191
+ },
1192
+ {
1193
+ group: [
1194
+ "vitest",
1195
+ ],
1196
+ message: "Importing from vitest is only allowed in test files.",
1197
+ },
1198
+ ],
1199
+ },
1200
+ ],
1201
+ },
1202
+ },
1203
+ {
1204
+ files: [
1205
+ "**/eslint.config.ts",
1206
+ "**/eslint.config.js",
1207
+ ],
1208
+ rules: {
1209
+ "no-restricted-exports": "off",
1210
+ },
1211
+ },
1212
+ {
1213
+ plugins: {
1214
+ headers: plugin0001,
1215
+ },
1216
+ rules: {
1217
+ "headers/header-format": [
1218
+ "error",
1219
+ {
1220
+ source: "string",
1221
+ style: "line",
1222
+ content: "(C) (years) GoodData Corporation",
1223
+ patterns: {
1224
+ years: {
1225
+ pattern: "\\d{4}(-\\d{4})?",
1226
+ defaultValue: "2026",
1227
+ },
1228
+ },
1229
+ },
1230
+ ],
1231
+ },
1232
+ },
1233
+ {
1234
+ languageOptions: {
1235
+ parser: plugin0003,
1236
+ sourceType: "module",
1237
+ },
1238
+ plugins: {
1239
+ "@typescript-eslint": plugin0002,
1240
+ },
1241
+ },
1242
+ {
1243
+ files: [
1244
+ "**/*.ts",
1245
+ "**/*.tsx",
1246
+ "**/*.mts",
1247
+ "**/*.cts",
1248
+ ],
1249
+ languageOptions: {
1250
+ parserOptions: {
1251
+ projectService: true,
1252
+ },
1253
+ },
1254
+ rules: {
1255
+ "constructor-super": "off",
1256
+ "getter-return": "off",
1257
+ "no-class-assign": "off",
1258
+ "no-const-assign": "off",
1259
+ "no-dupe-args": "off",
1260
+ "no-dupe-class-members": "off",
1261
+ "no-dupe-keys": "off",
1262
+ "no-func-assign": "off",
1263
+ "no-import-assign": "off",
1264
+ "no-new-native-nonconstructor": "off",
1265
+ "no-new-symbol": "off",
1266
+ "no-obj-calls": "off",
1267
+ "no-redeclare": "off",
1268
+ "no-setter-return": "off",
1269
+ "no-this-before-super": "off",
1270
+ "no-undef": "off",
1271
+ "no-unreachable": "off",
1272
+ "no-unsafe-negation": "off",
1273
+ "no-var": "error",
1274
+ "no-with": "off",
1275
+ "prefer-const": "error",
1276
+ "prefer-rest-params": "error",
1277
+ "prefer-spread": "error",
1278
+ "no-array-constructor": "off",
1279
+ "no-unused-expressions": "off",
1280
+ "no-unused-vars": "off",
1281
+ "@typescript-eslint/no-array-constructor": "error",
1282
+ "@typescript-eslint/no-duplicate-enum-values": "error",
1283
+ "@typescript-eslint/no-empty-object-type": "error",
1284
+ "@typescript-eslint/no-extra-non-null-assertion": "error",
1285
+ "@typescript-eslint/no-misused-new": "error",
1286
+ "@typescript-eslint/no-namespace": "error",
1287
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "error",
1288
+ "@typescript-eslint/no-require-imports": "error",
1289
+ "@typescript-eslint/no-this-alias": "error",
1290
+ "@typescript-eslint/no-unnecessary-type-constraint": "error",
1291
+ "@typescript-eslint/no-unsafe-declaration-merging": "error",
1292
+ "@typescript-eslint/no-unused-expressions": "error",
1293
+ "@typescript-eslint/prefer-as-const": "error",
1294
+ "@typescript-eslint/prefer-namespace-keyword": "error",
1295
+ "@typescript-eslint/triple-slash-reference": "error",
1296
+ "@typescript-eslint/explicit-function-return-type": 0,
1297
+ "@typescript-eslint/no-use-before-define": 0,
1298
+ "@typescript-eslint/no-empty-function": 0,
1299
+ "@typescript-eslint/naming-convention": [
1300
+ "error",
1301
+ {
1302
+ selector: "interface",
1303
+ format: [
1304
+ "PascalCase",
1305
+ ],
1306
+ custom: {
1307
+ regex: "^I[A-Z]",
1308
+ match: true,
1309
+ },
1310
+ },
1311
+ ],
1312
+ "@typescript-eslint/no-unused-vars": [
1313
+ 2,
1314
+ {
1315
+ varsIgnorePattern: "^_.*$",
1316
+ argsIgnorePattern: "^_.*$",
1317
+ },
1318
+ ],
1319
+ "@typescript-eslint/no-explicit-any": "error",
1320
+ "@typescript-eslint/array-type": "off",
1321
+ "@typescript-eslint/ban-ts-comment": [
1322
+ "error",
1323
+ {
1324
+ "ts-expect-error": "allow-with-description",
1325
+ },
1326
+ ],
1327
+ "@typescript-eslint/no-wrapper-object-types": "error",
1328
+ "@typescript-eslint/no-unsafe-function-type": "error",
1329
+ "@typescript-eslint/no-restricted-types": [
1330
+ "error",
1331
+ {
1332
+ types: {
1333
+ String: {
1334
+ message: "Use 'string' instead",
1335
+ fixWith: "string",
1336
+ },
1337
+ Number: {
1338
+ message: "Use 'number' instead",
1339
+ fixWith: "number",
1340
+ },
1341
+ Boolean: {
1342
+ message: "Use 'boolean' instead",
1343
+ fixWith: "boolean",
1344
+ },
1345
+ Symbol: {
1346
+ message: "Use 'symbol' instead",
1347
+ fixWith: "symbol",
1348
+ },
1349
+ },
1350
+ },
1351
+ ],
1352
+ "@typescript-eslint/consistent-type-exports": [
1353
+ "error",
1354
+ {
1355
+ fixMixedExportsWithInlineTypeSpecifier: false,
1356
+ },
1357
+ ],
1358
+ "@typescript-eslint/explicit-member-accessibility": "off",
1359
+ "@typescript-eslint/interface-name-prefix": "off",
1360
+ "@typescript-eslint/member-ordering": "off",
1361
+ "@typescript-eslint/no-inferrable-types": "off",
1362
+ "@typescript-eslint/no-non-null-assertion": "off",
1363
+ "@typescript-eslint/prefer-optional-chain": "error",
1364
+ "no-restricted-syntax": [
1365
+ "error",
1366
+ {
1367
+ selector: "MemberExpression[object.name='React']",
1368
+ message: "Do not use `React.*`. Use named imports instead.",
1369
+ },
1370
+ {
1371
+ selector: "TSTypeReference[typeName.type='TSQualifiedName'][typeName.left.name='React']",
1372
+ message: "Do not use `React.*` types. Use named imports instead.",
1373
+ },
1374
+ {
1375
+ selector: "ExportNamespaceSpecifier",
1376
+ message: "Usage of 'export * as …' is forbidden.",
1377
+ },
1378
+ {
1379
+ selector: "ExportAllDeclaration",
1380
+ message: "Usage of `export * from` is forbidden.",
1381
+ },
1382
+ {
1383
+ selector: "ImportDeclaration[source.value=/^(?!.*reference_workspace)\\./] ImportNamespaceSpecifier",
1384
+ message: "Do not use `import * as ...` from relative paths.",
1385
+ },
1386
+ ],
1387
+ "@typescript-eslint/consistent-type-imports": [
1388
+ "error",
1389
+ {
1390
+ prefer: "type-imports",
1391
+ fixStyle: "inline-type-imports",
1392
+ },
1393
+ ],
1394
+ },
1395
+ },
1396
+ {
1397
+ plugins: {
1398
+ "no-barrel-files": plugin0004,
1399
+ },
1400
+ rules: {
1401
+ "no-barrel-files/no-barrel-files": "error",
1402
+ },
1403
+ },
1404
+ {
1405
+ plugins: {
1406
+ "import-x": plugin0005,
1407
+ },
1408
+ settings: {
1409
+ "import-x/extensions": [
1410
+ ".js",
1411
+ ".jsx",
1412
+ ".mjs",
1413
+ ".cjs",
1414
+ ],
1415
+ },
1416
+ rules: {
1417
+ "import-x/no-unresolved": "error",
1418
+ "import-x/named": "error",
1419
+ "import-x/namespace": "error",
1420
+ "import-x/default": "error",
1421
+ "import-x/export": "error",
1422
+ "import-x/no-named-as-default": "warn",
1423
+ "import-x/no-named-as-default-member": "warn",
1424
+ "import-x/no-duplicates": "warn",
1425
+ "import-x/order": [
1426
+ "error",
1427
+ {
1428
+ pathGroups: [
1429
+ {
1430
+ pattern: "react",
1431
+ group: "external",
1432
+ position: "before",
1433
+ },
1434
+ {
1435
+ pattern: "@gooddata/**",
1436
+ group: "external",
1437
+ position: "after",
1438
+ },
1439
+ ],
1440
+ groups: [
1441
+ "builtin",
1442
+ "external",
1443
+ "internal",
1444
+ [
1445
+ "parent",
1446
+ "sibling",
1447
+ "index",
1448
+ ],
1449
+ ],
1450
+ pathGroupsExcludedImportTypes: [
1451
+ "react",
1452
+ ],
1453
+ alphabetize: {
1454
+ order: "asc",
1455
+ caseInsensitive: true,
1456
+ },
1457
+ "newlines-between": "always",
1458
+ },
1459
+ ],
1460
+ "import-x/no-unassigned-import": "error",
1461
+ },
1462
+ },
1463
+ {
1464
+ files: [
1465
+ "**/*.ts",
1466
+ "**/*.cts",
1467
+ "**/*.mts",
1468
+ "**/*.tsx",
1469
+ ],
1470
+ settings: {
1471
+ "import-x/extensions": [
1472
+ ".ts",
1473
+ ".cts",
1474
+ ".mts",
1475
+ ".tsx",
1476
+ ".js",
1477
+ ".jsx",
1478
+ ".mjs",
1479
+ ".cjs",
1480
+ ],
1481
+ "import-x/external-module-folders": [
1482
+ "node_modules",
1483
+ "node_modules/@types",
1484
+ ],
1485
+ "import-x/parsers": {
1486
+ "@typescript-eslint/parser": [
1487
+ ".ts",
1488
+ ".cts",
1489
+ ".mts",
1490
+ ".tsx",
1491
+ ],
1492
+ },
1493
+ "import-x/resolver": {
1494
+ typescript: {
1495
+ alwaysTryTypes: true,
1496
+ },
1497
+ },
1498
+ },
1499
+ rules: {
1500
+ "import-x/named": "off",
1501
+ },
1502
+ },
1503
+ {
1504
+ files: [
1505
+ "**/*.{js,cjs,mjs,jsx}",
1506
+ ],
1507
+ plugins: {
1508
+ jsdoc: plugin0006,
1509
+ },
1510
+ settings: {
1511
+ jsdoc: {
1512
+ mode: "jsdoc",
1513
+ },
1514
+ },
1515
+ rules: {
1516
+ "jsdoc/require-param": "error",
1517
+ },
1518
+ },
1519
+ {
1520
+ plugins: {
1521
+ sonarjs: plugin0007,
1522
+ },
1523
+ rules: {
1524
+ "sonarjs/function-name": "off",
1525
+ "sonarjs/max-lines": "off",
1526
+ "sonarjs/no-tab": "off",
1527
+ "sonarjs/variable-name": "off",
1528
+ "sonarjs/comment-regex": "off",
1529
+ "sonarjs/elseif-without-else": "off",
1530
+ "sonarjs/no-fallthrough": "error",
1531
+ "sonarjs/nested-control-flow": "off",
1532
+ "sonarjs/too-many-break-or-continue-in-loop": "off",
1533
+ "sonarjs/max-lines-per-function": "off",
1534
+ "sonarjs/no-nested-incdec": "off",
1535
+ "sonarjs/no-equals-in-for-termination": "error",
1536
+ "sonarjs/no-extra-arguments": "error",
1537
+ "sonarjs/no-collapsible-if": "off",
1538
+ "sonarjs/expression-complexity": "off",
1539
+ "sonarjs/no-redundant-parentheses": "off",
1540
+ "sonarjs/no-labels": "error",
1541
+ "sonarjs/no-redundant-boolean": "error",
1542
+ "sonarjs/prefer-single-boolean-return": "error",
1543
+ "sonarjs/unused-import": "error",
1544
+ "sonarjs/useless-string-operation": "off",
1545
+ "sonarjs/no-unused-function-argument": "off",
1546
+ "sonarjs/no-case-label-in-switch": "error",
1547
+ "sonarjs/no-parameter-reassignment": "error",
1548
+ "sonarjs/prefer-while": "error",
1549
+ "sonarjs/no-sonar-comments": "off",
1550
+ "sonarjs/no-small-switch": "error",
1551
+ "sonarjs/no-hardcoded-ip": "error",
1552
+ "sonarjs/label-position": "error",
1553
+ "sonarjs/file-header": "off",
1554
+ "sonarjs/call-argument-line": "error",
1555
+ "sonarjs/max-switch-cases": "error",
1556
+ "sonarjs/prefer-immediate-return": "off",
1557
+ "sonarjs/function-inside-loop": "error",
1558
+ "sonarjs/no-variable-usage-before-declaration": "off",
1559
+ "sonarjs/future-reserved-words": "error",
1560
+ "sonarjs/array-constructor": "off",
1561
+ "sonarjs/bitwise-operators": "error",
1562
+ "sonarjs/no-function-declaration-in-block": "off",
1563
+ "sonarjs/no-primitive-wrappers": "error",
1564
+ "sonarjs/for-in": "off",
1565
+ "sonarjs/cyclomatic-complexity": "off",
1566
+ "sonarjs/no-identical-expressions": "error",
1567
+ "sonarjs/no-nested-switch": "off",
1568
+ "sonarjs/no-identical-conditions": "error",
1569
+ "sonarjs/no-duplicated-branches": "error",
1570
+ "sonarjs/misplaced-loop-counter": "error",
1571
+ "sonarjs/sql-queries": "error",
1572
+ "sonarjs/insecure-cookie": "error",
1573
+ "sonarjs/no-useless-increment": "error",
1574
+ "sonarjs/no-undefined-assignment": "off",
1575
+ "sonarjs/no-wildcard-import": "off",
1576
+ "sonarjs/for-loop-increment-sign": "error",
1577
+ "sonarjs/cookies": "off",
1578
+ "sonarjs/null-dereference": "error",
1579
+ "sonarjs/updated-loop-counter": "error",
1580
+ "sonarjs/block-scoped-var": "error",
1581
+ "sonarjs/no-built-in-override": "off",
1582
+ "sonarjs/prefer-object-literal": "off",
1583
+ "sonarjs/no-gratuitous-expressions": "error",
1584
+ "sonarjs/file-uploads": "error",
1585
+ "sonarjs/file-permissions": "error",
1586
+ "sonarjs/no-empty-character-class": "error",
1587
+ "sonarjs/no-unenclosed-multiline-block": "error",
1588
+ "sonarjs/index-of-compare-to-positive-number": "error",
1589
+ "sonarjs/no-useless-catch": "error",
1590
+ "sonarjs/xml-parser-xxe": "error",
1591
+ "sonarjs/non-existent-operator": "error",
1592
+ "sonarjs/web-sql-database": "off",
1593
+ "sonarjs/no-array-delete": "error",
1594
+ "sonarjs/no-incomplete-assertions": "error",
1595
+ "sonarjs/no-global-this": "error",
1596
+ "sonarjs/new-operator-misuse": "error",
1597
+ "sonarjs/no-delete-var": "error",
1598
+ "sonarjs/strings-comparison": "off",
1599
+ "sonarjs/file-name-differ-from-class": "off",
1600
+ "sonarjs/cookie-no-httponly": "error",
1601
+ "sonarjs/no-incorrect-string-concat": "off",
1602
+ "sonarjs/inverted-assertion-arguments": "error",
1603
+ "sonarjs/shorthand-property-grouping": "off",
1604
+ "sonarjs/updated-const-var": "error",
1605
+ "sonarjs/arguments-usage": "off",
1606
+ "sonarjs/destructuring-assignment-syntax": "off",
1607
+ "sonarjs/arrow-function-convention": "off",
1608
+ "sonarjs/class-prototype": "off",
1609
+ "sonarjs/no-require-or-define": "off",
1610
+ "sonarjs/no-associative-arrays": "error",
1611
+ "sonarjs/comma-or-logical-or-case": "error",
1612
+ "sonarjs/no-redundant-jump": "error",
1613
+ "sonarjs/inconsistent-function-call": "error",
1614
+ "sonarjs/no-use-of-empty-return-value": "error",
1615
+ "sonarjs/enforce-trailing-comma": "off",
1616
+ "sonarjs/operation-returning-nan": "off",
1617
+ "sonarjs/values-not-convertible-to-numbers": "off",
1618
+ "sonarjs/non-number-in-arithmetic-expression": "off",
1619
+ "sonarjs/in-operator-type-error": "error",
1620
+ "sonarjs/declarations-in-global-scope": "off",
1621
+ "sonarjs/no-inconsistent-returns": "off",
1622
+ "sonarjs/no-reference-error": "off",
1623
+ "sonarjs/super-invocation": "error",
1624
+ "sonarjs/no-all-duplicated-branches": "error",
1625
+ "sonarjs/no-same-line-conditional": "error",
1626
+ "sonarjs/conditional-indentation": "off",
1627
+ "sonarjs/no-collection-size-mischeck": "error",
1628
+ "sonarjs/no-unthrown-error": "error",
1629
+ "sonarjs/no-unused-collection": "error",
1630
+ "sonarjs/no-for-in-iterable": "off",
1631
+ "sonarjs/no-element-overwrite": "error",
1632
+ "sonarjs/no-identical-functions": "error",
1633
+ "sonarjs/no-empty-collection": "error",
1634
+ "sonarjs/no-redundant-assignments": "error",
1635
+ "sonarjs/prefer-type-guard": "error",
1636
+ "sonarjs/no-return-type-any": "off",
1637
+ "sonarjs/no-implicit-dependencies": "off",
1638
+ "sonarjs/weak-ssl": "error",
1639
+ "sonarjs/no-weak-keys": "error",
1640
+ "sonarjs/csrf": "error",
1641
+ "sonarjs/production-debug": "error",
1642
+ "sonarjs/no-in-misuse": "error",
1643
+ "sonarjs/no-duplicate-in-composite": "error",
1644
+ "sonarjs/max-union-size": "off",
1645
+ "sonarjs/no-nested-template-literals": "error",
1646
+ "sonarjs/regular-expr": "off",
1647
+ "sonarjs/encryption": "off",
1648
+ "sonarjs/hashing": "error",
1649
+ "sonarjs/bool-param-default": "off",
1650
+ "sonarjs/xpath": "off",
1651
+ "sonarjs/sockets": "off",
1652
+ "sonarjs/process-argv": "off",
1653
+ "sonarjs/standard-input": "off",
1654
+ "sonarjs/unverified-certificate": "error",
1655
+ "sonarjs/cors": "error",
1656
+ "sonarjs/disabled-auto-escaping": "error",
1657
+ "sonarjs/no-table-as-layout": "error",
1658
+ "sonarjs/table-header-reference": "error",
1659
+ "sonarjs/object-alt-content": "error",
1660
+ "sonarjs/publicly-writable-directories": "error",
1661
+ "sonarjs/unverified-hostname": "error",
1662
+ "sonarjs/encryption-secure-mode": "error",
1663
+ "sonarjs/no-weak-cipher": "error",
1664
+ "sonarjs/no-intrusive-permissions": "error",
1665
+ "sonarjs/insecure-jwt-token": "error",
1666
+ "sonarjs/x-powered-by": "error",
1667
+ "sonarjs/hidden-files": "error",
1668
+ "sonarjs/content-length": "error",
1669
+ "sonarjs/disabled-resource-integrity": "error",
1670
+ "sonarjs/content-security-policy": "error",
1671
+ "sonarjs/no-mixed-content": "error",
1672
+ "sonarjs/frame-ancestors": "error",
1673
+ "sonarjs/no-mime-sniff": "error",
1674
+ "sonarjs/no-referrer-policy": "error",
1675
+ "sonarjs/strict-transport-security": "error",
1676
+ "sonarjs/certificate-transparency": "off",
1677
+ "sonarjs/dns-prefetching": "off",
1678
+ "sonarjs/confidential-information-logging": "error",
1679
+ "sonarjs/no-ip-forward": "error",
1680
+ "sonarjs/no-invalid-regexp": "error",
1681
+ "sonarjs/unused-named-groups": "error",
1682
+ "sonarjs/no-same-argument-assert": "error",
1683
+ "sonarjs/unicode-aware-regex": "off",
1684
+ "sonarjs/no-misleading-character-class": "error",
1685
+ "sonarjs/session-regeneration": "error",
1686
+ "sonarjs/test-check-exception": "error",
1687
+ "sonarjs/stable-tests": "error",
1688
+ "sonarjs/no-empty-after-reluctant": "error",
1689
+ "sonarjs/no-code-after-done": "error",
1690
+ "sonarjs/disabled-timeout": "error",
1691
+ "sonarjs/chai-determinate-assertion": "error",
1692
+ "sonarjs/aws-s3-bucket-server-encryption": "off",
1693
+ "sonarjs/aws-s3-bucket-insecure-http": "error",
1694
+ "sonarjs/aws-s3-bucket-versioning": "error",
1695
+ "sonarjs/aws-s3-bucket-granted-access": "error",
1696
+ "sonarjs/no-angular-bypass-sanitization": "error",
1697
+ "sonarjs/aws-iam-public-access": "error",
1698
+ "sonarjs/aws-ec2-unencrypted-ebs-volume": "error",
1699
+ "sonarjs/aws-s3-bucket-public-access": "error",
1700
+ "sonarjs/no-vue-bypass-sanitization": "off",
1701
+ "sonarjs/aws-iam-all-privileges": "error",
1702
+ "sonarjs/aws-rds-unencrypted-databases": "error",
1703
+ "sonarjs/aws-iam-all-resources-accessible": "off",
1704
+ "sonarjs/aws-opensearchservice-domain": "error",
1705
+ "sonarjs/aws-iam-privilege-escalation": "error",
1706
+ "sonarjs/aws-sagemaker-unencrypted-notebook": "error",
1707
+ "sonarjs/aws-restricted-ip-admin-access": "error",
1708
+ "sonarjs/no-empty-alternatives": "error",
1709
+ "sonarjs/no-regex-spaces": "error",
1710
+ "sonarjs/aws-sns-unencrypted-topics": "error",
1711
+ "sonarjs/existing-groups": "error",
1712
+ "sonarjs/aws-ec2-rds-dms-public": "error",
1713
+ "sonarjs/aws-sqs-unencrypted-queue": "error",
1714
+ "sonarjs/no-empty-group": "error",
1715
+ "sonarjs/aws-efs-unencrypted": "error",
1716
+ "sonarjs/aws-apigateway-public-api": "error",
1717
+ "sonarjs/stateful-regex": "error",
1718
+ "sonarjs/single-char-in-character-classes": "error",
1719
+ "sonarjs/no-exclusive-tests": "error",
1720
+ "sonarjs/hardcoded-secret-signatures": "error",
1721
+ "sonarjs/jsx-no-leaked-render": "error",
1722
+ "sonarjs/no-hook-setter-in-body": "error",
1723
+ "sonarjs/no-uniq-key": "error",
1724
+ "sonarjs/no-internal-api-use": "error",
1725
+ "sonarjs/no-literal-call": "error",
1726
+ "sonarjs/review-blockchain-mnemonic": "error",
1727
+ "sonarjs/dynamically-constructed-templates": "error",
1728
+ "sonarjs/no-duplicate-string": "off",
1729
+ "sonarjs/cognitive-complexity": "warn",
1730
+ "sonarjs/todo-tag": "warn",
1731
+ "sonarjs/no-hardcoded-passwords": "off",
1732
+ "sonarjs/no-alphabetical-sort": "off",
1733
+ "sonarjs/no-os-command-from-path": "off",
1734
+ "sonarjs/os-command": "off",
1735
+ "sonarjs/prefer-regexp-exec": "off",
1736
+ "sonarjs/no-clear-text-protocols": "off",
1737
+ "sonarjs/deprecation": "off",
1738
+ "sonarjs/no-nested-conditional": "off",
1739
+ "sonarjs/no-ignored-exceptions": "off",
1740
+ "sonarjs/slow-regex": "off",
1741
+ "sonarjs/prefer-read-only-props": "off",
1742
+ "sonarjs/no-skipped-tests": "off",
1743
+ "sonarjs/no-commented-code": "off",
1744
+ "sonarjs/no-ignored-return": "off",
1745
+ "sonarjs/array-callback-without-return": "off",
1746
+ "sonarjs/pseudo-random": "off",
1747
+ "sonarjs/no-nested-functions": "off",
1748
+ "sonarjs/no-async-constructor": "off",
1749
+ "sonarjs/assertions-in-tests": "off",
1750
+ "sonarjs/function-return-type": "off",
1751
+ "sonarjs/no-unused-vars": "off",
1752
+ "sonarjs/no-invariant-returns": "off",
1753
+ "sonarjs/different-types-comparison": "off",
1754
+ "sonarjs/no-selector-parameter": "off",
1755
+ "sonarjs/anchor-precedence": "off",
1756
+ "sonarjs/redundant-type-aliases": "off",
1757
+ "sonarjs/no-redundant-optional": "off",
1758
+ "sonarjs/reduce-initial-value": "off",
1759
+ "sonarjs/no-globals-shadowing": "off",
1760
+ "sonarjs/use-type-alias": "off",
1761
+ "sonarjs/void-use": "off",
1762
+ "sonarjs/no-undefined-argument": "off",
1763
+ "sonarjs/no-useless-react-setstate": "off",
1764
+ "sonarjs/no-inverted-boolean-check": "off",
1765
+ "sonarjs/concise-regex": "off",
1766
+ "sonarjs/no-dead-store": "off",
1767
+ "sonarjs/public-static-readonly": "off",
1768
+ "sonarjs/code-eval": "off",
1769
+ "sonarjs/no-misleading-array-reverse": "off",
1770
+ "sonarjs/fixme-tag": "off",
1771
+ "sonarjs/argument-type": "off",
1772
+ "sonarjs/constructor-for-side-effects": "off",
1773
+ "sonarjs/no-useless-intersection": "off",
1774
+ "sonarjs/no-empty-test-file": "off",
1775
+ "sonarjs/prefer-default-last": "off",
1776
+ "sonarjs/prefer-promise-shorthand": "off",
1777
+ "sonarjs/no-unsafe-unzip": "off",
1778
+ "sonarjs/no-nested-assignment": "off",
1779
+ "sonarjs/generator-without-yield": "off",
1780
+ "sonarjs/no-try-promise": "off",
1781
+ "sonarjs/single-character-alternation": "off",
1782
+ "sonarjs/class-name": "off",
1783
+ "sonarjs/no-hardcoded-secrets": "off",
1784
+ "sonarjs/regex-complexity": "off",
1785
+ "sonarjs/post-message": "off",
1786
+ "sonarjs/link-with-target-blank": "off",
1787
+ "sonarjs/duplicates-in-character-class": "off",
1788
+ "sonarjs/arguments-order": "off",
1789
+ "sonarjs/empty-string-repetition": "off",
1790
+ "sonarjs/table-header": "off",
1791
+ "sonarjs/no-implicit-global": "off",
1792
+ "sonarjs/no-control-regex": "off",
1793
+ },
1794
+ },
1795
+ {
1796
+ files: [
1797
+ "*.test.ts",
1798
+ "*.test.tsx",
1799
+ "*.spec.ts",
1800
+ ],
1801
+ rules: {
1802
+ "sonarjs/no-identical-functions": "off",
1803
+ },
1804
+ },
1805
+ {
1806
+ rules: {
1807
+ "no-caller": 2,
1808
+ "no-eval": 2,
1809
+ "no-delete-var": 2,
1810
+ "no-octal-escape": 2,
1811
+ },
1812
+ },
1813
+ {
1814
+ ignores: [
1815
+ "**/dist/**/*.*",
1816
+ "**/esm/**/*.*",
1817
+ "**/node_modules/**/*.*",
1818
+ "**/ci/results/**",
1819
+ "**/__version.ts",
1820
+ "**/cypress/results/**",
1821
+ "**/cypress/screenshots/**",
1822
+ "**/cypress/videos/**",
1823
+ "**/temp/**",
1824
+ ],
1825
+ },
1826
+ {
1827
+ rules: {
1828
+ curly: 0,
1829
+ "no-unexpected-multiline": 0,
1830
+ "@typescript-eslint/lines-around-comment": 0,
1831
+ "@typescript-eslint/quotes": 0,
1832
+ "unicorn/template-indent": 0,
1833
+ "@typescript-eslint/block-spacing": "off",
1834
+ "@typescript-eslint/brace-style": "off",
1835
+ "@typescript-eslint/comma-dangle": "off",
1836
+ "@typescript-eslint/comma-spacing": "off",
1837
+ "@typescript-eslint/func-call-spacing": "off",
1838
+ "@typescript-eslint/indent": "off",
1839
+ "@typescript-eslint/key-spacing": "off",
1840
+ "@typescript-eslint/keyword-spacing": "off",
1841
+ "@typescript-eslint/member-delimiter-style": "off",
1842
+ "@typescript-eslint/no-extra-parens": "off",
1843
+ "@typescript-eslint/no-extra-semi": "off",
1844
+ "@typescript-eslint/object-curly-spacing": "off",
1845
+ "@typescript-eslint/semi": "off",
1846
+ "@typescript-eslint/space-before-blocks": "off",
1847
+ "@typescript-eslint/space-before-function-paren": "off",
1848
+ "@typescript-eslint/space-infix-ops": "off",
1849
+ "@typescript-eslint/type-annotation-spacing": "off",
1850
+ "react/jsx-child-element-spacing": "off",
1851
+ "react/jsx-closing-bracket-location": "off",
1852
+ "react/jsx-closing-tag-location": "off",
1853
+ "react/jsx-curly-newline": "off",
1854
+ "react/jsx-curly-spacing": "off",
1855
+ "react/jsx-equals-spacing": "off",
1856
+ "react/jsx-first-prop-new-line": "off",
1857
+ "react/jsx-indent": "off",
1858
+ "react/jsx-indent-props": "off",
1859
+ "react/jsx-max-props-per-line": "off",
1860
+ "react/jsx-newline": "off",
1861
+ "react/jsx-one-expression-per-line": "off",
1862
+ "react/jsx-props-no-multi-spaces": "off",
1863
+ "react/jsx-tag-spacing": "off",
1864
+ "react/jsx-wrap-multilines": "off",
1865
+ "unicorn/empty-brace-spaces": "off",
1866
+ "unicorn/no-nested-ternary": "off",
1867
+ "unicorn/number-literal-case": "off",
1868
+ },
1869
+ },
1870
+ {
1871
+ languageOptions: {
1872
+ ecmaVersion: 2022,
1873
+ sourceType: "module",
1874
+ },
1875
+ },
1876
+ {
1877
+ plugins: {
1878
+ "import-esm": plugin0008,
1879
+ },
1880
+ rules: {
1881
+ "import-esm/explicit-extension": "error",
1882
+ },
1883
+ },
1884
+ ];