@gooddata/eslint-config 11.19.0-alpha.1 → 11.19.0-alpha.3

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