@gooddata/eslint-config 11.51.0-alpha.4 → 11.51.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2512 @@
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-react";
12
+ import plugin0009 from "eslint-plugin-react-hooks";
13
+ import plugin0010 from "eslint-plugin-import-esm";
14
+ import plugin0011 from "@vitest/eslint-plugin";
15
+ import plugin0012 from "eslint-plugin-testing-library";
16
+ import plugin0013 from "eslint-plugin-no-only-tests";
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-fallthrough": "error",
51
+ "no-func-assign": "error",
52
+ "no-global-assign": "error",
53
+ "no-import-assign": "error",
54
+ "no-invalid-regexp": "error",
55
+ "no-irregular-whitespace": "error",
56
+ "no-loss-of-precision": "error",
57
+ "no-misleading-character-class": "error",
58
+ "no-new-native-nonconstructor": "error",
59
+ "no-nonoctal-decimal-escape": "error",
60
+ "no-obj-calls": "error",
61
+ "no-octal": "error",
62
+ "no-prototype-builtins": "error",
63
+ "no-redeclare": "error",
64
+ "no-regex-spaces": "error",
65
+ "no-self-assign": "error",
66
+ "no-setter-return": "error",
67
+ "no-shadow-restricted-names": "error",
68
+ "no-sparse-arrays": "error",
69
+ "no-this-before-super": "error",
70
+ "no-undef": "error",
71
+ "no-unreachable": "error",
72
+ "no-unsafe-finally": "error",
73
+ "no-unsafe-negation": "error",
74
+ "no-unsafe-optional-chaining": "error",
75
+ "no-unused-labels": "error",
76
+ "no-unused-private-class-members": "error",
77
+ "no-unused-vars": "error",
78
+ "no-useless-backreference": "error",
79
+ "no-useless-catch": "error",
80
+ "no-with": "error",
81
+ "require-yield": "error",
82
+ "use-isnan": "error",
83
+ "valid-typeof": "error",
84
+ "no-restricted-imports": [
85
+ "error",
86
+ {
87
+ paths: [
88
+ {
89
+ name: "react",
90
+ importNames: [
91
+ "default",
92
+ ],
93
+ message: "Default import from React is not allowed. Use named imports instead.",
94
+ },
95
+ {
96
+ name: "react-dom",
97
+ importNames: [
98
+ "default",
99
+ ],
100
+ message: "Default import from React DOM is not allowed. Use named imports instead.",
101
+ },
102
+ {
103
+ name: "@gooddata/sdk-ui-kit",
104
+ importNames: [
105
+ "Icon",
106
+ ],
107
+ message: "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead.",
108
+ },
109
+ {
110
+ name: "vitest",
111
+ importNames: [
112
+ "test",
113
+ ],
114
+ message: "Use 'it' instead of 'test' for consistency.",
115
+ },
116
+ ],
117
+ patterns: [
118
+ {
119
+ group: [
120
+ "lodash-es",
121
+ ],
122
+ importNames: [
123
+ "get",
124
+ "getOr",
125
+ ],
126
+ message: "Please use the ?. and ?? operators instead.",
127
+ },
128
+ {
129
+ group: [
130
+ "lodash-es",
131
+ ],
132
+ importNames: [
133
+ "keys",
134
+ ],
135
+ message: "Please use Object.keys() instead.",
136
+ },
137
+ {
138
+ group: [
139
+ "lodash-es",
140
+ ],
141
+ importNames: [
142
+ "values",
143
+ ],
144
+ message: "Please use Object.values() instead.",
145
+ },
146
+ {
147
+ group: [
148
+ "lodash-es",
149
+ ],
150
+ importNames: [
151
+ "entries",
152
+ "toPairs",
153
+ ],
154
+ message: "Please use Object.entries() instead.",
155
+ },
156
+ {
157
+ group: [
158
+ "lodash-es",
159
+ ],
160
+ importNames: [
161
+ "map",
162
+ ],
163
+ message: "Please use Array.prototype.map() instead.",
164
+ },
165
+ {
166
+ group: [
167
+ "lodash-es",
168
+ ],
169
+ importNames: [
170
+ "flatMap",
171
+ ],
172
+ message: "Please use Array.prototype.flatMap() instead.",
173
+ },
174
+ {
175
+ group: [
176
+ "lodash-es",
177
+ ],
178
+ importNames: [
179
+ "filter",
180
+ ],
181
+ message: "Please use Array.prototype.filter() instead.",
182
+ },
183
+ {
184
+ group: [
185
+ "lodash-es",
186
+ ],
187
+ importNames: [
188
+ "find",
189
+ ],
190
+ message: "Please use Array.prototype.find() instead.",
191
+ },
192
+ {
193
+ group: [
194
+ "lodash-es",
195
+ ],
196
+ importNames: [
197
+ "findIndex",
198
+ ],
199
+ message: "Please use Array.prototype.findIndex() instead.",
200
+ },
201
+ {
202
+ group: [
203
+ "lodash-es",
204
+ ],
205
+ importNames: [
206
+ "includes",
207
+ ],
208
+ message: "Please use Array.prototype.includes() instead.",
209
+ },
210
+ {
211
+ group: [
212
+ "lodash-es",
213
+ ],
214
+ importNames: [
215
+ "some",
216
+ ],
217
+ message: "Please use Array.prototype.some() instead.",
218
+ },
219
+ {
220
+ group: [
221
+ "lodash-es",
222
+ ],
223
+ importNames: [
224
+ "every",
225
+ ],
226
+ message: "Please use Array.prototype.every() instead.",
227
+ },
228
+ {
229
+ group: [
230
+ "lodash-es",
231
+ ],
232
+ importNames: [
233
+ "concat",
234
+ ],
235
+ message: "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead.",
236
+ },
237
+ {
238
+ group: [
239
+ "lodash-es",
240
+ ],
241
+ importNames: [
242
+ "reverse",
243
+ ],
244
+ message: "Please use Array.prototype.reverse() instead.",
245
+ },
246
+ {
247
+ group: [
248
+ "lodash-es",
249
+ ],
250
+ importNames: [
251
+ "slice",
252
+ ],
253
+ message: "Please use Array.prototype.slice() instead.",
254
+ },
255
+ {
256
+ group: [
257
+ "lodash-es",
258
+ ],
259
+ importNames: [
260
+ "indexOf",
261
+ ],
262
+ message: "Please use Array.prototype.indexOf() instead.",
263
+ },
264
+ {
265
+ group: [
266
+ "lodash-es",
267
+ ],
268
+ importNames: [
269
+ "lastIndexOf",
270
+ ],
271
+ message: "Please use Array.prototype.lastIndexOf() instead.",
272
+ },
273
+ {
274
+ group: [
275
+ "lodash-es",
276
+ ],
277
+ importNames: [
278
+ "fill",
279
+ ],
280
+ message: "Please use Array.prototype.fill() instead.",
281
+ },
282
+ {
283
+ group: [
284
+ "lodash-es",
285
+ ],
286
+ importNames: [
287
+ "startsWith",
288
+ ],
289
+ message: "Please use String.prototype.startsWith() instead.",
290
+ },
291
+ {
292
+ group: [
293
+ "lodash-es",
294
+ ],
295
+ importNames: [
296
+ "endsWith",
297
+ ],
298
+ message: "Please use String.prototype.endsWith() instead.",
299
+ },
300
+ {
301
+ group: [
302
+ "lodash-es",
303
+ ],
304
+ importNames: [
305
+ "repeat",
306
+ ],
307
+ message: "Please use String.prototype.repeat() instead.",
308
+ },
309
+ {
310
+ group: [
311
+ "lodash-es",
312
+ ],
313
+ importNames: [
314
+ "padStart",
315
+ ],
316
+ message: "Please use String.prototype.padStart() instead.",
317
+ },
318
+ {
319
+ group: [
320
+ "lodash-es",
321
+ ],
322
+ importNames: [
323
+ "padEnd",
324
+ ],
325
+ message: "Please use String.prototype.padEnd() instead.",
326
+ },
327
+ {
328
+ group: [
329
+ "lodash-es",
330
+ ],
331
+ importNames: [
332
+ "trim",
333
+ ],
334
+ message: "Please use String.prototype.trim() instead.",
335
+ },
336
+ {
337
+ group: [
338
+ "lodash-es",
339
+ ],
340
+ importNames: [
341
+ "trimStart",
342
+ "trimLeft",
343
+ ],
344
+ message: "Please use String.prototype.trimStart() instead.",
345
+ },
346
+ {
347
+ group: [
348
+ "lodash-es",
349
+ ],
350
+ importNames: [
351
+ "trimEnd",
352
+ "trimRight",
353
+ ],
354
+ message: "Please use String.prototype.trimEnd() instead.",
355
+ },
356
+ {
357
+ group: [
358
+ "lodash-es",
359
+ ],
360
+ importNames: [
361
+ "toUpper",
362
+ ],
363
+ message: "Please use String.prototype.toUpperCase() instead.",
364
+ },
365
+ {
366
+ group: [
367
+ "lodash-es",
368
+ ],
369
+ importNames: [
370
+ "toLower",
371
+ ],
372
+ message: "Please use String.prototype.toLowerCase() instead.",
373
+ },
374
+ {
375
+ group: [
376
+ "lodash-es",
377
+ ],
378
+ importNames: [
379
+ "isArray",
380
+ ],
381
+ message: "Please use Array.isArray() instead.",
382
+ },
383
+ {
384
+ group: [
385
+ "lodash-es",
386
+ ],
387
+ importNames: [
388
+ "isNaN",
389
+ ],
390
+ message: "Please use Number.isNaN() instead.",
391
+ },
392
+ {
393
+ group: [
394
+ "lodash-es",
395
+ ],
396
+ importNames: [
397
+ "isFinite",
398
+ ],
399
+ message: "Please use Number.isFinite() instead.",
400
+ },
401
+ {
402
+ group: [
403
+ "lodash-es",
404
+ ],
405
+ importNames: [
406
+ "isInteger",
407
+ ],
408
+ message: "Please use Number.isInteger() instead.",
409
+ },
410
+ {
411
+ group: [
412
+ "lodash-es",
413
+ ],
414
+ importNames: [
415
+ "isNull",
416
+ ],
417
+ message: "Please use value === null instead.",
418
+ },
419
+ {
420
+ group: [
421
+ "lodash-es",
422
+ ],
423
+ importNames: [
424
+ "isUndefined",
425
+ ],
426
+ message: "Please use value === undefined instead.",
427
+ },
428
+ {
429
+ group: [
430
+ "lodash-es",
431
+ ],
432
+ importNames: [
433
+ "defaultTo",
434
+ ],
435
+ message: "Please use value ?? defaultValue instead.",
436
+ },
437
+ {
438
+ group: [
439
+ "lodash-es",
440
+ ],
441
+ importNames: [
442
+ "assign",
443
+ ],
444
+ message: "Please use Object.assign() or spread syntax {...obj} instead.",
445
+ },
446
+ {
447
+ group: [
448
+ "lodash-es",
449
+ ],
450
+ importNames: [
451
+ "flatten",
452
+ ],
453
+ message: "Please use Array.prototype.flat() instead.",
454
+ },
455
+ {
456
+ group: [
457
+ "lodash-es",
458
+ ],
459
+ importNames: [
460
+ "flattenDeep",
461
+ ],
462
+ message: "Please use Array.prototype.flat(Infinity) instead.",
463
+ },
464
+ {
465
+ group: [
466
+ "lodash-es",
467
+ ],
468
+ importNames: [
469
+ "isNil",
470
+ ],
471
+ message: "Please use value === null || value === undefined instead.",
472
+ },
473
+ {
474
+ group: [
475
+ "lodash-es",
476
+ ],
477
+ importNames: [
478
+ "noop",
479
+ ],
480
+ message: "Please use () => {} instead.",
481
+ },
482
+ {
483
+ group: [
484
+ "lodash-es",
485
+ ],
486
+ importNames: [
487
+ "identity",
488
+ ],
489
+ message: "Please use x => x instead.",
490
+ },
491
+ {
492
+ group: [
493
+ "lodash-es",
494
+ ],
495
+ importNames: [
496
+ "first",
497
+ "head",
498
+ ],
499
+ message: "Please use Array.prototype.at(0) instead.",
500
+ },
501
+ {
502
+ group: [
503
+ "lodash-es",
504
+ ],
505
+ importNames: [
506
+ "last",
507
+ ],
508
+ message: "Please use Array.prototype.at(-1) instead.",
509
+ },
510
+ {
511
+ group: [
512
+ "lodash-es",
513
+ ],
514
+ importNames: [
515
+ "forEach",
516
+ ],
517
+ message: "Please use Array.prototype.forEach() instead.",
518
+ },
519
+ {
520
+ group: [
521
+ "lodash-es",
522
+ ],
523
+ importNames: [
524
+ "fromPairs",
525
+ ],
526
+ message: "Please use Object.fromEntries() instead.",
527
+ },
528
+ {
529
+ group: [
530
+ "lodash-es",
531
+ ],
532
+ importNames: [
533
+ "join",
534
+ ],
535
+ message: "Please use Array.prototype.join() instead.",
536
+ },
537
+ {
538
+ group: [
539
+ "lodash-es",
540
+ ],
541
+ importNames: [
542
+ "isDate",
543
+ ],
544
+ message: "Please use val instanceof Date instead.",
545
+ },
546
+ {
547
+ group: [
548
+ "lodash-es",
549
+ ],
550
+ importNames: [
551
+ "isFunction",
552
+ ],
553
+ message: "Please use typeof val === 'function' instead.",
554
+ },
555
+ {
556
+ group: [
557
+ "lodash-es",
558
+ ],
559
+ importNames: [
560
+ "isNumber",
561
+ ],
562
+ message: "Please use typeof val === 'number' instead.",
563
+ },
564
+ {
565
+ group: [
566
+ "lodash-es",
567
+ ],
568
+ importNames: [
569
+ "isObject",
570
+ ],
571
+ message: "Please use val !== null && typeof val === 'object' instead.",
572
+ },
573
+ {
574
+ group: [
575
+ "lodash-es",
576
+ ],
577
+ importNames: [
578
+ "isString",
579
+ ],
580
+ message: "Please use typeof val === 'string' instead.",
581
+ },
582
+ {
583
+ group: [
584
+ "lodash-es",
585
+ ],
586
+ importNames: [
587
+ "toString",
588
+ ],
589
+ message: "Please use String(val) instead.",
590
+ },
591
+ {
592
+ group: [
593
+ "lodash-es",
594
+ ],
595
+ importNames: [
596
+ "flow",
597
+ "flowRight",
598
+ ],
599
+ message: "Please use refactoring your code instead.",
600
+ },
601
+ ],
602
+ },
603
+ ],
604
+ "sort-imports": [
605
+ "error",
606
+ {
607
+ ignoreCase: false,
608
+ ignoreDeclarationSort: true,
609
+ ignoreMemberSort: false,
610
+ },
611
+ ],
612
+ "no-useless-escape": "off",
613
+ "no-unneeded-ternary": [
614
+ "error",
615
+ {
616
+ defaultAssignment: false,
617
+ },
618
+ ],
619
+ "no-extra-boolean-cast": "error",
620
+ "no-unexpected-multiline": "off",
621
+ "no-duplicate-imports": [
622
+ "error",
623
+ {
624
+ includeExports: true,
625
+ },
626
+ ],
627
+ "prefer-const": "off",
628
+ "no-console": [
629
+ 2,
630
+ {
631
+ allow: [
632
+ "warn",
633
+ "error",
634
+ ],
635
+ },
636
+ ],
637
+ "no-restricted-exports": [
638
+ 2,
639
+ {
640
+ restrictDefaultExports: {
641
+ direct: true,
642
+ named: true,
643
+ defaultFrom: true,
644
+ namedFrom: true,
645
+ namespaceFrom: true,
646
+ },
647
+ },
648
+ ],
649
+ "no-restricted-syntax": [
650
+ "error",
651
+ {
652
+ selector: "MemberExpression[object.name='React']",
653
+ message: "Do not use `React.*`. Use named imports instead.",
654
+ },
655
+ {
656
+ selector: "MemberExpression[object.name='ReactDOM']",
657
+ message: "Do not use `ReactDOM.*`. Use named imports instead.",
658
+ },
659
+ ],
660
+ "no-negated-condition": "error",
661
+ },
662
+ },
663
+ {
664
+ files: [
665
+ "**/*.ts",
666
+ "**/*.tsx",
667
+ ],
668
+ rules: {
669
+ "no-restricted-imports": [
670
+ "error",
671
+ {
672
+ paths: [
673
+ {
674
+ name: "react",
675
+ importNames: [
676
+ "default",
677
+ ],
678
+ message: "Default import from React is not allowed. Use named imports instead.",
679
+ },
680
+ {
681
+ name: "react-dom",
682
+ importNames: [
683
+ "default",
684
+ ],
685
+ message: "Default import from React DOM is not allowed. Use named imports instead.",
686
+ },
687
+ {
688
+ name: "@gooddata/sdk-ui-kit",
689
+ importNames: [
690
+ "Icon",
691
+ ],
692
+ message: "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead.",
693
+ },
694
+ {
695
+ name: "vitest",
696
+ importNames: [
697
+ "test",
698
+ ],
699
+ message: "Use 'it' instead of 'test' for consistency.",
700
+ },
701
+ ],
702
+ patterns: [
703
+ {
704
+ group: [
705
+ "lodash-es",
706
+ ],
707
+ importNames: [
708
+ "get",
709
+ "getOr",
710
+ ],
711
+ message: "Please use the ?. and ?? operators instead.",
712
+ },
713
+ {
714
+ group: [
715
+ "lodash-es",
716
+ ],
717
+ importNames: [
718
+ "keys",
719
+ ],
720
+ message: "Please use Object.keys() instead.",
721
+ },
722
+ {
723
+ group: [
724
+ "lodash-es",
725
+ ],
726
+ importNames: [
727
+ "values",
728
+ ],
729
+ message: "Please use Object.values() instead.",
730
+ },
731
+ {
732
+ group: [
733
+ "lodash-es",
734
+ ],
735
+ importNames: [
736
+ "entries",
737
+ "toPairs",
738
+ ],
739
+ message: "Please use Object.entries() instead.",
740
+ },
741
+ {
742
+ group: [
743
+ "lodash-es",
744
+ ],
745
+ importNames: [
746
+ "map",
747
+ ],
748
+ message: "Please use Array.prototype.map() instead.",
749
+ },
750
+ {
751
+ group: [
752
+ "lodash-es",
753
+ ],
754
+ importNames: [
755
+ "flatMap",
756
+ ],
757
+ message: "Please use Array.prototype.flatMap() instead.",
758
+ },
759
+ {
760
+ group: [
761
+ "lodash-es",
762
+ ],
763
+ importNames: [
764
+ "filter",
765
+ ],
766
+ message: "Please use Array.prototype.filter() instead.",
767
+ },
768
+ {
769
+ group: [
770
+ "lodash-es",
771
+ ],
772
+ importNames: [
773
+ "find",
774
+ ],
775
+ message: "Please use Array.prototype.find() instead.",
776
+ },
777
+ {
778
+ group: [
779
+ "lodash-es",
780
+ ],
781
+ importNames: [
782
+ "findIndex",
783
+ ],
784
+ message: "Please use Array.prototype.findIndex() instead.",
785
+ },
786
+ {
787
+ group: [
788
+ "lodash-es",
789
+ ],
790
+ importNames: [
791
+ "includes",
792
+ ],
793
+ message: "Please use Array.prototype.includes() instead.",
794
+ },
795
+ {
796
+ group: [
797
+ "lodash-es",
798
+ ],
799
+ importNames: [
800
+ "some",
801
+ ],
802
+ message: "Please use Array.prototype.some() instead.",
803
+ },
804
+ {
805
+ group: [
806
+ "lodash-es",
807
+ ],
808
+ importNames: [
809
+ "every",
810
+ ],
811
+ message: "Please use Array.prototype.every() instead.",
812
+ },
813
+ {
814
+ group: [
815
+ "lodash-es",
816
+ ],
817
+ importNames: [
818
+ "concat",
819
+ ],
820
+ message: "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead.",
821
+ },
822
+ {
823
+ group: [
824
+ "lodash-es",
825
+ ],
826
+ importNames: [
827
+ "reverse",
828
+ ],
829
+ message: "Please use Array.prototype.reverse() instead.",
830
+ },
831
+ {
832
+ group: [
833
+ "lodash-es",
834
+ ],
835
+ importNames: [
836
+ "slice",
837
+ ],
838
+ message: "Please use Array.prototype.slice() instead.",
839
+ },
840
+ {
841
+ group: [
842
+ "lodash-es",
843
+ ],
844
+ importNames: [
845
+ "indexOf",
846
+ ],
847
+ message: "Please use Array.prototype.indexOf() instead.",
848
+ },
849
+ {
850
+ group: [
851
+ "lodash-es",
852
+ ],
853
+ importNames: [
854
+ "lastIndexOf",
855
+ ],
856
+ message: "Please use Array.prototype.lastIndexOf() instead.",
857
+ },
858
+ {
859
+ group: [
860
+ "lodash-es",
861
+ ],
862
+ importNames: [
863
+ "fill",
864
+ ],
865
+ message: "Please use Array.prototype.fill() instead.",
866
+ },
867
+ {
868
+ group: [
869
+ "lodash-es",
870
+ ],
871
+ importNames: [
872
+ "startsWith",
873
+ ],
874
+ message: "Please use String.prototype.startsWith() instead.",
875
+ },
876
+ {
877
+ group: [
878
+ "lodash-es",
879
+ ],
880
+ importNames: [
881
+ "endsWith",
882
+ ],
883
+ message: "Please use String.prototype.endsWith() instead.",
884
+ },
885
+ {
886
+ group: [
887
+ "lodash-es",
888
+ ],
889
+ importNames: [
890
+ "repeat",
891
+ ],
892
+ message: "Please use String.prototype.repeat() instead.",
893
+ },
894
+ {
895
+ group: [
896
+ "lodash-es",
897
+ ],
898
+ importNames: [
899
+ "padStart",
900
+ ],
901
+ message: "Please use String.prototype.padStart() instead.",
902
+ },
903
+ {
904
+ group: [
905
+ "lodash-es",
906
+ ],
907
+ importNames: [
908
+ "padEnd",
909
+ ],
910
+ message: "Please use String.prototype.padEnd() instead.",
911
+ },
912
+ {
913
+ group: [
914
+ "lodash-es",
915
+ ],
916
+ importNames: [
917
+ "trim",
918
+ ],
919
+ message: "Please use String.prototype.trim() instead.",
920
+ },
921
+ {
922
+ group: [
923
+ "lodash-es",
924
+ ],
925
+ importNames: [
926
+ "trimStart",
927
+ "trimLeft",
928
+ ],
929
+ message: "Please use String.prototype.trimStart() instead.",
930
+ },
931
+ {
932
+ group: [
933
+ "lodash-es",
934
+ ],
935
+ importNames: [
936
+ "trimEnd",
937
+ "trimRight",
938
+ ],
939
+ message: "Please use String.prototype.trimEnd() instead.",
940
+ },
941
+ {
942
+ group: [
943
+ "lodash-es",
944
+ ],
945
+ importNames: [
946
+ "toUpper",
947
+ ],
948
+ message: "Please use String.prototype.toUpperCase() instead.",
949
+ },
950
+ {
951
+ group: [
952
+ "lodash-es",
953
+ ],
954
+ importNames: [
955
+ "toLower",
956
+ ],
957
+ message: "Please use String.prototype.toLowerCase() instead.",
958
+ },
959
+ {
960
+ group: [
961
+ "lodash-es",
962
+ ],
963
+ importNames: [
964
+ "isArray",
965
+ ],
966
+ message: "Please use Array.isArray() instead.",
967
+ },
968
+ {
969
+ group: [
970
+ "lodash-es",
971
+ ],
972
+ importNames: [
973
+ "isNaN",
974
+ ],
975
+ message: "Please use Number.isNaN() instead.",
976
+ },
977
+ {
978
+ group: [
979
+ "lodash-es",
980
+ ],
981
+ importNames: [
982
+ "isFinite",
983
+ ],
984
+ message: "Please use Number.isFinite() instead.",
985
+ },
986
+ {
987
+ group: [
988
+ "lodash-es",
989
+ ],
990
+ importNames: [
991
+ "isInteger",
992
+ ],
993
+ message: "Please use Number.isInteger() instead.",
994
+ },
995
+ {
996
+ group: [
997
+ "lodash-es",
998
+ ],
999
+ importNames: [
1000
+ "isNull",
1001
+ ],
1002
+ message: "Please use value === null instead.",
1003
+ },
1004
+ {
1005
+ group: [
1006
+ "lodash-es",
1007
+ ],
1008
+ importNames: [
1009
+ "isUndefined",
1010
+ ],
1011
+ message: "Please use value === undefined instead.",
1012
+ },
1013
+ {
1014
+ group: [
1015
+ "lodash-es",
1016
+ ],
1017
+ importNames: [
1018
+ "defaultTo",
1019
+ ],
1020
+ message: "Please use value ?? defaultValue instead.",
1021
+ },
1022
+ {
1023
+ group: [
1024
+ "lodash-es",
1025
+ ],
1026
+ importNames: [
1027
+ "assign",
1028
+ ],
1029
+ message: "Please use Object.assign() or spread syntax {...obj} instead.",
1030
+ },
1031
+ {
1032
+ group: [
1033
+ "lodash-es",
1034
+ ],
1035
+ importNames: [
1036
+ "flatten",
1037
+ ],
1038
+ message: "Please use Array.prototype.flat() instead.",
1039
+ },
1040
+ {
1041
+ group: [
1042
+ "lodash-es",
1043
+ ],
1044
+ importNames: [
1045
+ "flattenDeep",
1046
+ ],
1047
+ message: "Please use Array.prototype.flat(Infinity) instead.",
1048
+ },
1049
+ {
1050
+ group: [
1051
+ "lodash-es",
1052
+ ],
1053
+ importNames: [
1054
+ "isNil",
1055
+ ],
1056
+ message: "Please use value === null || value === undefined instead.",
1057
+ },
1058
+ {
1059
+ group: [
1060
+ "lodash-es",
1061
+ ],
1062
+ importNames: [
1063
+ "noop",
1064
+ ],
1065
+ message: "Please use () => {} instead.",
1066
+ },
1067
+ {
1068
+ group: [
1069
+ "lodash-es",
1070
+ ],
1071
+ importNames: [
1072
+ "identity",
1073
+ ],
1074
+ message: "Please use x => x instead.",
1075
+ },
1076
+ {
1077
+ group: [
1078
+ "lodash-es",
1079
+ ],
1080
+ importNames: [
1081
+ "first",
1082
+ "head",
1083
+ ],
1084
+ message: "Please use Array.prototype.at(0) instead.",
1085
+ },
1086
+ {
1087
+ group: [
1088
+ "lodash-es",
1089
+ ],
1090
+ importNames: [
1091
+ "last",
1092
+ ],
1093
+ message: "Please use Array.prototype.at(-1) instead.",
1094
+ },
1095
+ {
1096
+ group: [
1097
+ "lodash-es",
1098
+ ],
1099
+ importNames: [
1100
+ "forEach",
1101
+ ],
1102
+ message: "Please use Array.prototype.forEach() instead.",
1103
+ },
1104
+ {
1105
+ group: [
1106
+ "lodash-es",
1107
+ ],
1108
+ importNames: [
1109
+ "fromPairs",
1110
+ ],
1111
+ message: "Please use Object.fromEntries() instead.",
1112
+ },
1113
+ {
1114
+ group: [
1115
+ "lodash-es",
1116
+ ],
1117
+ importNames: [
1118
+ "join",
1119
+ ],
1120
+ message: "Please use Array.prototype.join() instead.",
1121
+ },
1122
+ {
1123
+ group: [
1124
+ "lodash-es",
1125
+ ],
1126
+ importNames: [
1127
+ "isDate",
1128
+ ],
1129
+ message: "Please use val instanceof Date instead.",
1130
+ },
1131
+ {
1132
+ group: [
1133
+ "lodash-es",
1134
+ ],
1135
+ importNames: [
1136
+ "isFunction",
1137
+ ],
1138
+ message: "Please use typeof val === 'function' instead.",
1139
+ },
1140
+ {
1141
+ group: [
1142
+ "lodash-es",
1143
+ ],
1144
+ importNames: [
1145
+ "isNumber",
1146
+ ],
1147
+ message: "Please use typeof val === 'number' instead.",
1148
+ },
1149
+ {
1150
+ group: [
1151
+ "lodash-es",
1152
+ ],
1153
+ importNames: [
1154
+ "isObject",
1155
+ ],
1156
+ message: "Please use val !== null && typeof val === 'object' instead.",
1157
+ },
1158
+ {
1159
+ group: [
1160
+ "lodash-es",
1161
+ ],
1162
+ importNames: [
1163
+ "isString",
1164
+ ],
1165
+ message: "Please use typeof val === 'string' instead.",
1166
+ },
1167
+ {
1168
+ group: [
1169
+ "lodash-es",
1170
+ ],
1171
+ importNames: [
1172
+ "toString",
1173
+ ],
1174
+ message: "Please use String(val) instead.",
1175
+ },
1176
+ {
1177
+ group: [
1178
+ "lodash-es",
1179
+ ],
1180
+ importNames: [
1181
+ "flow",
1182
+ "flowRight",
1183
+ ],
1184
+ message: "Please use refactoring your code instead.",
1185
+ },
1186
+ {
1187
+ group: [
1188
+ "vitest",
1189
+ ],
1190
+ message: "Importing from vitest is only allowed in test files.",
1191
+ },
1192
+ ],
1193
+ },
1194
+ ],
1195
+ },
1196
+ },
1197
+ {
1198
+ files: [
1199
+ "**/vitest.config.ts",
1200
+ "**/vitest.*.config.ts",
1201
+ "**/vitest.setup.ts",
1202
+ "**/vitest.setup.tsx",
1203
+ "**/*.test.ts",
1204
+ "**/*.test.tsx",
1205
+ "**/*.test.utils.ts",
1206
+ "**/*.test.utils.tsx",
1207
+ "**/*.test.helpers.ts",
1208
+ "**/*.test.helpers.tsx",
1209
+ ],
1210
+ rules: {
1211
+ "no-restricted-imports": [
1212
+ "error",
1213
+ {
1214
+ paths: [
1215
+ {
1216
+ name: "react",
1217
+ importNames: [
1218
+ "default",
1219
+ ],
1220
+ message: "Default import from React is not allowed. Use named imports instead.",
1221
+ },
1222
+ {
1223
+ name: "react-dom",
1224
+ importNames: [
1225
+ "default",
1226
+ ],
1227
+ message: "Default import from React DOM is not allowed. Use named imports instead.",
1228
+ },
1229
+ {
1230
+ name: "@gooddata/sdk-ui-kit",
1231
+ importNames: [
1232
+ "Icon",
1233
+ ],
1234
+ message: "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead.",
1235
+ },
1236
+ {
1237
+ name: "vitest",
1238
+ importNames: [
1239
+ "test",
1240
+ ],
1241
+ message: "Use 'it' instead of 'test' for consistency.",
1242
+ },
1243
+ ],
1244
+ patterns: [
1245
+ {
1246
+ group: [
1247
+ "lodash-es",
1248
+ ],
1249
+ importNames: [
1250
+ "get",
1251
+ "getOr",
1252
+ ],
1253
+ message: "Please use the ?. and ?? operators instead.",
1254
+ },
1255
+ {
1256
+ group: [
1257
+ "lodash-es",
1258
+ ],
1259
+ importNames: [
1260
+ "keys",
1261
+ ],
1262
+ message: "Please use Object.keys() instead.",
1263
+ },
1264
+ {
1265
+ group: [
1266
+ "lodash-es",
1267
+ ],
1268
+ importNames: [
1269
+ "values",
1270
+ ],
1271
+ message: "Please use Object.values() instead.",
1272
+ },
1273
+ {
1274
+ group: [
1275
+ "lodash-es",
1276
+ ],
1277
+ importNames: [
1278
+ "entries",
1279
+ "toPairs",
1280
+ ],
1281
+ message: "Please use Object.entries() instead.",
1282
+ },
1283
+ {
1284
+ group: [
1285
+ "lodash-es",
1286
+ ],
1287
+ importNames: [
1288
+ "map",
1289
+ ],
1290
+ message: "Please use Array.prototype.map() instead.",
1291
+ },
1292
+ {
1293
+ group: [
1294
+ "lodash-es",
1295
+ ],
1296
+ importNames: [
1297
+ "flatMap",
1298
+ ],
1299
+ message: "Please use Array.prototype.flatMap() instead.",
1300
+ },
1301
+ {
1302
+ group: [
1303
+ "lodash-es",
1304
+ ],
1305
+ importNames: [
1306
+ "filter",
1307
+ ],
1308
+ message: "Please use Array.prototype.filter() instead.",
1309
+ },
1310
+ {
1311
+ group: [
1312
+ "lodash-es",
1313
+ ],
1314
+ importNames: [
1315
+ "find",
1316
+ ],
1317
+ message: "Please use Array.prototype.find() instead.",
1318
+ },
1319
+ {
1320
+ group: [
1321
+ "lodash-es",
1322
+ ],
1323
+ importNames: [
1324
+ "findIndex",
1325
+ ],
1326
+ message: "Please use Array.prototype.findIndex() instead.",
1327
+ },
1328
+ {
1329
+ group: [
1330
+ "lodash-es",
1331
+ ],
1332
+ importNames: [
1333
+ "includes",
1334
+ ],
1335
+ message: "Please use Array.prototype.includes() instead.",
1336
+ },
1337
+ {
1338
+ group: [
1339
+ "lodash-es",
1340
+ ],
1341
+ importNames: [
1342
+ "some",
1343
+ ],
1344
+ message: "Please use Array.prototype.some() instead.",
1345
+ },
1346
+ {
1347
+ group: [
1348
+ "lodash-es",
1349
+ ],
1350
+ importNames: [
1351
+ "every",
1352
+ ],
1353
+ message: "Please use Array.prototype.every() instead.",
1354
+ },
1355
+ {
1356
+ group: [
1357
+ "lodash-es",
1358
+ ],
1359
+ importNames: [
1360
+ "concat",
1361
+ ],
1362
+ message: "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead.",
1363
+ },
1364
+ {
1365
+ group: [
1366
+ "lodash-es",
1367
+ ],
1368
+ importNames: [
1369
+ "reverse",
1370
+ ],
1371
+ message: "Please use Array.prototype.reverse() instead.",
1372
+ },
1373
+ {
1374
+ group: [
1375
+ "lodash-es",
1376
+ ],
1377
+ importNames: [
1378
+ "slice",
1379
+ ],
1380
+ message: "Please use Array.prototype.slice() instead.",
1381
+ },
1382
+ {
1383
+ group: [
1384
+ "lodash-es",
1385
+ ],
1386
+ importNames: [
1387
+ "indexOf",
1388
+ ],
1389
+ message: "Please use Array.prototype.indexOf() instead.",
1390
+ },
1391
+ {
1392
+ group: [
1393
+ "lodash-es",
1394
+ ],
1395
+ importNames: [
1396
+ "lastIndexOf",
1397
+ ],
1398
+ message: "Please use Array.prototype.lastIndexOf() instead.",
1399
+ },
1400
+ {
1401
+ group: [
1402
+ "lodash-es",
1403
+ ],
1404
+ importNames: [
1405
+ "fill",
1406
+ ],
1407
+ message: "Please use Array.prototype.fill() instead.",
1408
+ },
1409
+ {
1410
+ group: [
1411
+ "lodash-es",
1412
+ ],
1413
+ importNames: [
1414
+ "startsWith",
1415
+ ],
1416
+ message: "Please use String.prototype.startsWith() instead.",
1417
+ },
1418
+ {
1419
+ group: [
1420
+ "lodash-es",
1421
+ ],
1422
+ importNames: [
1423
+ "endsWith",
1424
+ ],
1425
+ message: "Please use String.prototype.endsWith() instead.",
1426
+ },
1427
+ {
1428
+ group: [
1429
+ "lodash-es",
1430
+ ],
1431
+ importNames: [
1432
+ "repeat",
1433
+ ],
1434
+ message: "Please use String.prototype.repeat() instead.",
1435
+ },
1436
+ {
1437
+ group: [
1438
+ "lodash-es",
1439
+ ],
1440
+ importNames: [
1441
+ "padStart",
1442
+ ],
1443
+ message: "Please use String.prototype.padStart() instead.",
1444
+ },
1445
+ {
1446
+ group: [
1447
+ "lodash-es",
1448
+ ],
1449
+ importNames: [
1450
+ "padEnd",
1451
+ ],
1452
+ message: "Please use String.prototype.padEnd() instead.",
1453
+ },
1454
+ {
1455
+ group: [
1456
+ "lodash-es",
1457
+ ],
1458
+ importNames: [
1459
+ "trim",
1460
+ ],
1461
+ message: "Please use String.prototype.trim() instead.",
1462
+ },
1463
+ {
1464
+ group: [
1465
+ "lodash-es",
1466
+ ],
1467
+ importNames: [
1468
+ "trimStart",
1469
+ "trimLeft",
1470
+ ],
1471
+ message: "Please use String.prototype.trimStart() instead.",
1472
+ },
1473
+ {
1474
+ group: [
1475
+ "lodash-es",
1476
+ ],
1477
+ importNames: [
1478
+ "trimEnd",
1479
+ "trimRight",
1480
+ ],
1481
+ message: "Please use String.prototype.trimEnd() instead.",
1482
+ },
1483
+ {
1484
+ group: [
1485
+ "lodash-es",
1486
+ ],
1487
+ importNames: [
1488
+ "toUpper",
1489
+ ],
1490
+ message: "Please use String.prototype.toUpperCase() instead.",
1491
+ },
1492
+ {
1493
+ group: [
1494
+ "lodash-es",
1495
+ ],
1496
+ importNames: [
1497
+ "toLower",
1498
+ ],
1499
+ message: "Please use String.prototype.toLowerCase() instead.",
1500
+ },
1501
+ {
1502
+ group: [
1503
+ "lodash-es",
1504
+ ],
1505
+ importNames: [
1506
+ "isArray",
1507
+ ],
1508
+ message: "Please use Array.isArray() instead.",
1509
+ },
1510
+ {
1511
+ group: [
1512
+ "lodash-es",
1513
+ ],
1514
+ importNames: [
1515
+ "isNaN",
1516
+ ],
1517
+ message: "Please use Number.isNaN() instead.",
1518
+ },
1519
+ {
1520
+ group: [
1521
+ "lodash-es",
1522
+ ],
1523
+ importNames: [
1524
+ "isFinite",
1525
+ ],
1526
+ message: "Please use Number.isFinite() instead.",
1527
+ },
1528
+ {
1529
+ group: [
1530
+ "lodash-es",
1531
+ ],
1532
+ importNames: [
1533
+ "isInteger",
1534
+ ],
1535
+ message: "Please use Number.isInteger() instead.",
1536
+ },
1537
+ {
1538
+ group: [
1539
+ "lodash-es",
1540
+ ],
1541
+ importNames: [
1542
+ "isNull",
1543
+ ],
1544
+ message: "Please use value === null instead.",
1545
+ },
1546
+ {
1547
+ group: [
1548
+ "lodash-es",
1549
+ ],
1550
+ importNames: [
1551
+ "isUndefined",
1552
+ ],
1553
+ message: "Please use value === undefined instead.",
1554
+ },
1555
+ {
1556
+ group: [
1557
+ "lodash-es",
1558
+ ],
1559
+ importNames: [
1560
+ "defaultTo",
1561
+ ],
1562
+ message: "Please use value ?? defaultValue instead.",
1563
+ },
1564
+ {
1565
+ group: [
1566
+ "lodash-es",
1567
+ ],
1568
+ importNames: [
1569
+ "assign",
1570
+ ],
1571
+ message: "Please use Object.assign() or spread syntax {...obj} instead.",
1572
+ },
1573
+ {
1574
+ group: [
1575
+ "lodash-es",
1576
+ ],
1577
+ importNames: [
1578
+ "flatten",
1579
+ ],
1580
+ message: "Please use Array.prototype.flat() instead.",
1581
+ },
1582
+ {
1583
+ group: [
1584
+ "lodash-es",
1585
+ ],
1586
+ importNames: [
1587
+ "flattenDeep",
1588
+ ],
1589
+ message: "Please use Array.prototype.flat(Infinity) instead.",
1590
+ },
1591
+ {
1592
+ group: [
1593
+ "lodash-es",
1594
+ ],
1595
+ importNames: [
1596
+ "isNil",
1597
+ ],
1598
+ message: "Please use value === null || value === undefined instead.",
1599
+ },
1600
+ {
1601
+ group: [
1602
+ "lodash-es",
1603
+ ],
1604
+ importNames: [
1605
+ "noop",
1606
+ ],
1607
+ message: "Please use () => {} instead.",
1608
+ },
1609
+ {
1610
+ group: [
1611
+ "lodash-es",
1612
+ ],
1613
+ importNames: [
1614
+ "identity",
1615
+ ],
1616
+ message: "Please use x => x instead.",
1617
+ },
1618
+ {
1619
+ group: [
1620
+ "lodash-es",
1621
+ ],
1622
+ importNames: [
1623
+ "first",
1624
+ "head",
1625
+ ],
1626
+ message: "Please use Array.prototype.at(0) instead.",
1627
+ },
1628
+ {
1629
+ group: [
1630
+ "lodash-es",
1631
+ ],
1632
+ importNames: [
1633
+ "last",
1634
+ ],
1635
+ message: "Please use Array.prototype.at(-1) instead.",
1636
+ },
1637
+ {
1638
+ group: [
1639
+ "lodash-es",
1640
+ ],
1641
+ importNames: [
1642
+ "forEach",
1643
+ ],
1644
+ message: "Please use Array.prototype.forEach() instead.",
1645
+ },
1646
+ {
1647
+ group: [
1648
+ "lodash-es",
1649
+ ],
1650
+ importNames: [
1651
+ "fromPairs",
1652
+ ],
1653
+ message: "Please use Object.fromEntries() instead.",
1654
+ },
1655
+ {
1656
+ group: [
1657
+ "lodash-es",
1658
+ ],
1659
+ importNames: [
1660
+ "join",
1661
+ ],
1662
+ message: "Please use Array.prototype.join() instead.",
1663
+ },
1664
+ {
1665
+ group: [
1666
+ "lodash-es",
1667
+ ],
1668
+ importNames: [
1669
+ "isDate",
1670
+ ],
1671
+ message: "Please use val instanceof Date instead.",
1672
+ },
1673
+ {
1674
+ group: [
1675
+ "lodash-es",
1676
+ ],
1677
+ importNames: [
1678
+ "isFunction",
1679
+ ],
1680
+ message: "Please use typeof val === 'function' instead.",
1681
+ },
1682
+ {
1683
+ group: [
1684
+ "lodash-es",
1685
+ ],
1686
+ importNames: [
1687
+ "isNumber",
1688
+ ],
1689
+ message: "Please use typeof val === 'number' instead.",
1690
+ },
1691
+ {
1692
+ group: [
1693
+ "lodash-es",
1694
+ ],
1695
+ importNames: [
1696
+ "isObject",
1697
+ ],
1698
+ message: "Please use val !== null && typeof val === 'object' instead.",
1699
+ },
1700
+ {
1701
+ group: [
1702
+ "lodash-es",
1703
+ ],
1704
+ importNames: [
1705
+ "isString",
1706
+ ],
1707
+ message: "Please use typeof val === 'string' instead.",
1708
+ },
1709
+ {
1710
+ group: [
1711
+ "lodash-es",
1712
+ ],
1713
+ importNames: [
1714
+ "toString",
1715
+ ],
1716
+ message: "Please use String(val) instead.",
1717
+ },
1718
+ {
1719
+ group: [
1720
+ "lodash-es",
1721
+ ],
1722
+ importNames: [
1723
+ "flow",
1724
+ "flowRight",
1725
+ ],
1726
+ message: "Please use refactoring your code instead.",
1727
+ },
1728
+ ],
1729
+ },
1730
+ ],
1731
+ },
1732
+ },
1733
+ {
1734
+ files: [
1735
+ "**/eslint.config.ts",
1736
+ "**/eslint.config.js",
1737
+ ],
1738
+ rules: {
1739
+ "no-restricted-exports": "off",
1740
+ },
1741
+ },
1742
+ {
1743
+ plugins: {
1744
+ headers: plugin0001,
1745
+ },
1746
+ rules: {
1747
+ "headers/header-format": [
1748
+ "error",
1749
+ {
1750
+ source: "string",
1751
+ style: "line",
1752
+ content: "(C) (years) GoodData Corporation",
1753
+ patterns: {
1754
+ years: {
1755
+ pattern: "\\d{4}(-\\d{4})?",
1756
+ defaultValue: "2026",
1757
+ },
1758
+ },
1759
+ },
1760
+ ],
1761
+ },
1762
+ },
1763
+ {
1764
+ languageOptions: {
1765
+ parser: plugin0003,
1766
+ sourceType: "module",
1767
+ },
1768
+ plugins: {
1769
+ "@typescript-eslint": plugin0002,
1770
+ },
1771
+ },
1772
+ {
1773
+ files: [
1774
+ "**/*.ts",
1775
+ "**/*.tsx",
1776
+ "**/*.mts",
1777
+ "**/*.cts",
1778
+ ],
1779
+ languageOptions: {
1780
+ parserOptions: {
1781
+ projectService: true,
1782
+ },
1783
+ },
1784
+ rules: {
1785
+ "constructor-super": "off",
1786
+ "getter-return": "off",
1787
+ "no-class-assign": "off",
1788
+ "no-const-assign": "off",
1789
+ "no-dupe-args": "off",
1790
+ "no-dupe-class-members": "off",
1791
+ "no-dupe-keys": "off",
1792
+ "no-func-assign": "off",
1793
+ "no-import-assign": "off",
1794
+ "no-new-native-nonconstructor": "off",
1795
+ "no-new-symbol": "off",
1796
+ "no-obj-calls": "off",
1797
+ "no-redeclare": "off",
1798
+ "no-setter-return": "off",
1799
+ "no-this-before-super": "off",
1800
+ "no-undef": "off",
1801
+ "no-unreachable": "off",
1802
+ "no-unsafe-negation": "off",
1803
+ "no-var": "error",
1804
+ "no-with": "off",
1805
+ "prefer-const": "error",
1806
+ "prefer-rest-params": "error",
1807
+ "prefer-spread": "error",
1808
+ "no-array-constructor": "off",
1809
+ "no-unused-expressions": "off",
1810
+ "no-unused-vars": "off",
1811
+ "@typescript-eslint/no-array-constructor": "error",
1812
+ "@typescript-eslint/no-duplicate-enum-values": "error",
1813
+ "@typescript-eslint/no-empty-object-type": "error",
1814
+ "@typescript-eslint/no-extra-non-null-assertion": "error",
1815
+ "@typescript-eslint/no-misused-new": "error",
1816
+ "@typescript-eslint/no-namespace": "error",
1817
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "error",
1818
+ "@typescript-eslint/no-require-imports": "error",
1819
+ "@typescript-eslint/no-this-alias": "error",
1820
+ "@typescript-eslint/no-unnecessary-type-constraint": "error",
1821
+ "@typescript-eslint/no-unsafe-declaration-merging": "error",
1822
+ "@typescript-eslint/prefer-as-const": "error",
1823
+ "@typescript-eslint/prefer-namespace-keyword": "error",
1824
+ "@typescript-eslint/triple-slash-reference": "error",
1825
+ "@typescript-eslint/explicit-function-return-type": 0,
1826
+ "@typescript-eslint/no-use-before-define": 0,
1827
+ "@typescript-eslint/no-empty-function": 0,
1828
+ "@typescript-eslint/no-unused-vars": [
1829
+ 2,
1830
+ {
1831
+ varsIgnorePattern: "^_.*$",
1832
+ argsIgnorePattern: "^_.*$",
1833
+ },
1834
+ ],
1835
+ "@typescript-eslint/no-explicit-any": "error",
1836
+ "@typescript-eslint/array-type": "off",
1837
+ "@typescript-eslint/ban-ts-comment": [
1838
+ "error",
1839
+ {
1840
+ "ts-expect-error": "allow-with-description",
1841
+ },
1842
+ ],
1843
+ "@typescript-eslint/no-wrapper-object-types": "error",
1844
+ "@typescript-eslint/no-unsafe-function-type": "error",
1845
+ "@typescript-eslint/no-restricted-types": [
1846
+ "error",
1847
+ {
1848
+ types: {
1849
+ String: {
1850
+ message: "Use 'string' instead",
1851
+ fixWith: "string",
1852
+ },
1853
+ Number: {
1854
+ message: "Use 'number' instead",
1855
+ fixWith: "number",
1856
+ },
1857
+ Boolean: {
1858
+ message: "Use 'boolean' instead",
1859
+ fixWith: "boolean",
1860
+ },
1861
+ Symbol: {
1862
+ message: "Use 'symbol' instead",
1863
+ fixWith: "symbol",
1864
+ },
1865
+ },
1866
+ },
1867
+ ],
1868
+ "@typescript-eslint/explicit-member-accessibility": "off",
1869
+ "@typescript-eslint/interface-name-prefix": "off",
1870
+ "@typescript-eslint/member-ordering": "off",
1871
+ "@typescript-eslint/no-inferrable-types": "off",
1872
+ "@typescript-eslint/no-non-null-assertion": "off",
1873
+ "no-restricted-syntax": [
1874
+ "error",
1875
+ {
1876
+ selector: "MemberExpression[object.name='React']",
1877
+ message: "Do not use `React.*`. Use named imports instead.",
1878
+ },
1879
+ {
1880
+ selector: "TSTypeReference[typeName.type='TSQualifiedName'][typeName.left.name='React']",
1881
+ message: "Do not use `React.*` types. Use named imports instead.",
1882
+ },
1883
+ {
1884
+ selector: "ExportNamespaceSpecifier",
1885
+ message: "Usage of 'export * as …' is forbidden.",
1886
+ },
1887
+ {
1888
+ selector: "ExportAllDeclaration",
1889
+ message: "Usage of `export * from` is forbidden.",
1890
+ },
1891
+ {
1892
+ selector: "ImportDeclaration[source.value=/^(?!.*reference_workspace)\\./] ImportNamespaceSpecifier",
1893
+ message: "Do not use `import * as ...` from relative paths.",
1894
+ },
1895
+ ],
1896
+ "@typescript-eslint/consistent-type-imports": [
1897
+ "error",
1898
+ {
1899
+ prefer: "type-imports",
1900
+ fixStyle: "inline-type-imports",
1901
+ },
1902
+ ],
1903
+ "@typescript-eslint/prefer-optional-chain": "error",
1904
+ "@typescript-eslint/consistent-type-exports": [
1905
+ "error",
1906
+ {
1907
+ fixMixedExportsWithInlineTypeSpecifier: false,
1908
+ },
1909
+ ],
1910
+ "@typescript-eslint/naming-convention": [
1911
+ "error",
1912
+ {
1913
+ selector: "interface",
1914
+ format: [
1915
+ "PascalCase",
1916
+ ],
1917
+ custom: {
1918
+ regex: "^I[A-Z]",
1919
+ match: true,
1920
+ },
1921
+ },
1922
+ ],
1923
+ },
1924
+ },
1925
+ {
1926
+ plugins: {
1927
+ "no-barrel-files": plugin0004,
1928
+ },
1929
+ rules: {
1930
+ "no-barrel-files/no-barrel-files": "error",
1931
+ },
1932
+ },
1933
+ {
1934
+ files: [
1935
+ "**/eslint.config.ts",
1936
+ ],
1937
+ rules: {
1938
+ "no-barrel-files/no-barrel-files": "off",
1939
+ },
1940
+ },
1941
+ {
1942
+ plugins: {
1943
+ "import-x": plugin0005,
1944
+ },
1945
+ settings: {
1946
+ "import-x/extensions": [
1947
+ ".js",
1948
+ ".jsx",
1949
+ ".mjs",
1950
+ ".cjs",
1951
+ ],
1952
+ },
1953
+ rules: {
1954
+ "import-x/named": "error",
1955
+ "import-x/namespace": "error",
1956
+ "import-x/default": "error",
1957
+ "import-x/export": "error",
1958
+ "import-x/no-named-as-default": "warn",
1959
+ "import-x/no-named-as-default-member": "warn",
1960
+ "import-x/no-duplicates": "warn",
1961
+ "import-x/no-unassigned-import": "error",
1962
+ },
1963
+ },
1964
+ {
1965
+ files: [
1966
+ "**/*.ts",
1967
+ "**/*.cts",
1968
+ "**/*.mts",
1969
+ "**/*.tsx",
1970
+ ],
1971
+ settings: {
1972
+ "import-x/extensions": [
1973
+ ".ts",
1974
+ ".cts",
1975
+ ".mts",
1976
+ ".tsx",
1977
+ ".js",
1978
+ ".jsx",
1979
+ ".mjs",
1980
+ ".cjs",
1981
+ ],
1982
+ "import-x/external-module-folders": [
1983
+ "node_modules",
1984
+ "node_modules/@types",
1985
+ ],
1986
+ "import-x/parsers": {
1987
+ "@typescript-eslint/parser": [
1988
+ ".ts",
1989
+ ".cts",
1990
+ ".mts",
1991
+ ".tsx",
1992
+ ],
1993
+ },
1994
+ "import-x/resolver": {
1995
+ typescript: {
1996
+ alwaysTryTypes: true,
1997
+ },
1998
+ },
1999
+ },
2000
+ },
2001
+ {
2002
+ files: [
2003
+ "**/*.{js,cjs,mjs,jsx}",
2004
+ ],
2005
+ plugins: {
2006
+ jsdoc: plugin0006,
2007
+ },
2008
+ settings: {
2009
+ jsdoc: {
2010
+ mode: "jsdoc",
2011
+ },
2012
+ },
2013
+ rules: {
2014
+ "jsdoc/require-param": "error",
2015
+ },
2016
+ },
2017
+ {
2018
+ plugins: {
2019
+ sonarjs: plugin0007,
2020
+ },
2021
+ rules: {
2022
+ "sonarjs/function-name": "off",
2023
+ "sonarjs/max-lines": "off",
2024
+ "sonarjs/no-tab": "off",
2025
+ "sonarjs/variable-name": "off",
2026
+ "sonarjs/comment-regex": "off",
2027
+ "sonarjs/elseif-without-else": "off",
2028
+ "sonarjs/no-fallthrough": "error",
2029
+ "sonarjs/nested-control-flow": "off",
2030
+ "sonarjs/too-many-break-or-continue-in-loop": "off",
2031
+ "sonarjs/max-lines-per-function": "off",
2032
+ "sonarjs/no-nested-incdec": "off",
2033
+ "sonarjs/no-equals-in-for-termination": "error",
2034
+ "sonarjs/no-extra-arguments": "error",
2035
+ "sonarjs/no-collapsible-if": "off",
2036
+ "sonarjs/expression-complexity": "off",
2037
+ "sonarjs/no-redundant-parentheses": "off",
2038
+ "sonarjs/no-labels": "error",
2039
+ "sonarjs/no-redundant-boolean": "error",
2040
+ "sonarjs/prefer-single-boolean-return": "error",
2041
+ "sonarjs/unused-import": "error",
2042
+ "sonarjs/useless-string-operation": "off",
2043
+ "sonarjs/no-unused-function-argument": "off",
2044
+ "sonarjs/no-case-label-in-switch": "error",
2045
+ "sonarjs/no-parameter-reassignment": "error",
2046
+ "sonarjs/prefer-while": "error",
2047
+ "sonarjs/no-sonar-comments": "off",
2048
+ "sonarjs/no-small-switch": "error",
2049
+ "sonarjs/no-hardcoded-ip": "error",
2050
+ "sonarjs/label-position": "error",
2051
+ "sonarjs/file-header": "off",
2052
+ "sonarjs/call-argument-line": "error",
2053
+ "sonarjs/max-switch-cases": "error",
2054
+ "sonarjs/prefer-immediate-return": "off",
2055
+ "sonarjs/function-inside-loop": "error",
2056
+ "sonarjs/no-variable-usage-before-declaration": "off",
2057
+ "sonarjs/future-reserved-words": "error",
2058
+ "sonarjs/array-constructor": "off",
2059
+ "sonarjs/bitwise-operators": "error",
2060
+ "sonarjs/no-function-declaration-in-block": "off",
2061
+ "sonarjs/no-primitive-wrappers": "error",
2062
+ "sonarjs/for-in": "off",
2063
+ "sonarjs/cyclomatic-complexity": "off",
2064
+ "sonarjs/no-identical-expressions": "error",
2065
+ "sonarjs/no-nested-switch": "off",
2066
+ "sonarjs/no-identical-conditions": "error",
2067
+ "sonarjs/no-duplicated-branches": "error",
2068
+ "sonarjs/misplaced-loop-counter": "error",
2069
+ "sonarjs/sql-queries": "error",
2070
+ "sonarjs/insecure-cookie": "error",
2071
+ "sonarjs/no-useless-increment": "error",
2072
+ "sonarjs/no-undefined-assignment": "off",
2073
+ "sonarjs/no-wildcard-import": "off",
2074
+ "sonarjs/for-loop-increment-sign": "error",
2075
+ "sonarjs/cookies": "off",
2076
+ "sonarjs/null-dereference": "error",
2077
+ "sonarjs/updated-loop-counter": "error",
2078
+ "sonarjs/block-scoped-var": "error",
2079
+ "sonarjs/no-built-in-override": "off",
2080
+ "sonarjs/prefer-object-literal": "off",
2081
+ "sonarjs/no-gratuitous-expressions": "error",
2082
+ "sonarjs/file-uploads": "error",
2083
+ "sonarjs/file-permissions": "error",
2084
+ "sonarjs/no-empty-character-class": "error",
2085
+ "sonarjs/no-unenclosed-multiline-block": "error",
2086
+ "sonarjs/index-of-compare-to-positive-number": "error",
2087
+ "sonarjs/no-useless-catch": "error",
2088
+ "sonarjs/xml-parser-xxe": "error",
2089
+ "sonarjs/non-existent-operator": "error",
2090
+ "sonarjs/web-sql-database": "off",
2091
+ "sonarjs/no-array-delete": "error",
2092
+ "sonarjs/no-incomplete-assertions": "error",
2093
+ "sonarjs/no-global-this": "error",
2094
+ "sonarjs/new-operator-misuse": "error",
2095
+ "sonarjs/no-delete-var": "error",
2096
+ "sonarjs/strings-comparison": "off",
2097
+ "sonarjs/file-name-differ-from-class": "off",
2098
+ "sonarjs/cookie-no-httponly": "error",
2099
+ "sonarjs/no-incorrect-string-concat": "off",
2100
+ "sonarjs/inverted-assertion-arguments": "error",
2101
+ "sonarjs/shorthand-property-grouping": "off",
2102
+ "sonarjs/updated-const-var": "error",
2103
+ "sonarjs/arguments-usage": "off",
2104
+ "sonarjs/destructuring-assignment-syntax": "off",
2105
+ "sonarjs/arrow-function-convention": "off",
2106
+ "sonarjs/class-prototype": "off",
2107
+ "sonarjs/no-require-or-define": "off",
2108
+ "sonarjs/no-associative-arrays": "error",
2109
+ "sonarjs/comma-or-logical-or-case": "error",
2110
+ "sonarjs/no-redundant-jump": "error",
2111
+ "sonarjs/inconsistent-function-call": "error",
2112
+ "sonarjs/no-use-of-empty-return-value": "error",
2113
+ "sonarjs/enforce-trailing-comma": "off",
2114
+ "sonarjs/operation-returning-nan": "off",
2115
+ "sonarjs/values-not-convertible-to-numbers": "off",
2116
+ "sonarjs/non-number-in-arithmetic-expression": "off",
2117
+ "sonarjs/in-operator-type-error": "error",
2118
+ "sonarjs/declarations-in-global-scope": "off",
2119
+ "sonarjs/no-inconsistent-returns": "off",
2120
+ "sonarjs/no-reference-error": "off",
2121
+ "sonarjs/super-invocation": "error",
2122
+ "sonarjs/no-all-duplicated-branches": "error",
2123
+ "sonarjs/no-same-line-conditional": "error",
2124
+ "sonarjs/conditional-indentation": "off",
2125
+ "sonarjs/no-collection-size-mischeck": "error",
2126
+ "sonarjs/no-unthrown-error": "error",
2127
+ "sonarjs/no-unused-collection": "error",
2128
+ "sonarjs/no-for-in-iterable": "off",
2129
+ "sonarjs/no-element-overwrite": "error",
2130
+ "sonarjs/no-identical-functions": "error",
2131
+ "sonarjs/no-empty-collection": "error",
2132
+ "sonarjs/no-redundant-assignments": "error",
2133
+ "sonarjs/prefer-type-guard": "error",
2134
+ "sonarjs/no-return-type-any": "off",
2135
+ "sonarjs/no-implicit-dependencies": "off",
2136
+ "sonarjs/weak-ssl": "error",
2137
+ "sonarjs/no-weak-keys": "error",
2138
+ "sonarjs/csrf": "error",
2139
+ "sonarjs/production-debug": "error",
2140
+ "sonarjs/no-in-misuse": "error",
2141
+ "sonarjs/no-duplicate-in-composite": "error",
2142
+ "sonarjs/max-union-size": "off",
2143
+ "sonarjs/no-nested-template-literals": "error",
2144
+ "sonarjs/regular-expr": "off",
2145
+ "sonarjs/encryption": "off",
2146
+ "sonarjs/hashing": "error",
2147
+ "sonarjs/bool-param-default": "off",
2148
+ "sonarjs/xpath": "off",
2149
+ "sonarjs/sockets": "off",
2150
+ "sonarjs/process-argv": "off",
2151
+ "sonarjs/standard-input": "off",
2152
+ "sonarjs/unverified-certificate": "error",
2153
+ "sonarjs/cors": "error",
2154
+ "sonarjs/disabled-auto-escaping": "error",
2155
+ "sonarjs/no-table-as-layout": "error",
2156
+ "sonarjs/table-header-reference": "error",
2157
+ "sonarjs/object-alt-content": "error",
2158
+ "sonarjs/publicly-writable-directories": "error",
2159
+ "sonarjs/unverified-hostname": "error",
2160
+ "sonarjs/encryption-secure-mode": "error",
2161
+ "sonarjs/no-weak-cipher": "error",
2162
+ "sonarjs/no-intrusive-permissions": "error",
2163
+ "sonarjs/insecure-jwt-token": "error",
2164
+ "sonarjs/x-powered-by": "error",
2165
+ "sonarjs/hidden-files": "error",
2166
+ "sonarjs/content-length": "error",
2167
+ "sonarjs/disabled-resource-integrity": "error",
2168
+ "sonarjs/content-security-policy": "error",
2169
+ "sonarjs/no-mixed-content": "error",
2170
+ "sonarjs/frame-ancestors": "error",
2171
+ "sonarjs/no-mime-sniff": "error",
2172
+ "sonarjs/no-referrer-policy": "error",
2173
+ "sonarjs/strict-transport-security": "error",
2174
+ "sonarjs/certificate-transparency": "off",
2175
+ "sonarjs/dns-prefetching": "off",
2176
+ "sonarjs/confidential-information-logging": "error",
2177
+ "sonarjs/no-ip-forward": "error",
2178
+ "sonarjs/no-invalid-regexp": "error",
2179
+ "sonarjs/unused-named-groups": "error",
2180
+ "sonarjs/no-same-argument-assert": "error",
2181
+ "sonarjs/unicode-aware-regex": "off",
2182
+ "sonarjs/no-misleading-character-class": "error",
2183
+ "sonarjs/session-regeneration": "error",
2184
+ "sonarjs/test-check-exception": "error",
2185
+ "sonarjs/stable-tests": "error",
2186
+ "sonarjs/no-empty-after-reluctant": "error",
2187
+ "sonarjs/no-code-after-done": "error",
2188
+ "sonarjs/disabled-timeout": "error",
2189
+ "sonarjs/chai-determinate-assertion": "error",
2190
+ "sonarjs/aws-s3-bucket-server-encryption": "off",
2191
+ "sonarjs/aws-s3-bucket-insecure-http": "error",
2192
+ "sonarjs/aws-s3-bucket-versioning": "error",
2193
+ "sonarjs/aws-s3-bucket-granted-access": "error",
2194
+ "sonarjs/no-angular-bypass-sanitization": "error",
2195
+ "sonarjs/aws-iam-public-access": "error",
2196
+ "sonarjs/aws-ec2-unencrypted-ebs-volume": "error",
2197
+ "sonarjs/aws-s3-bucket-public-access": "error",
2198
+ "sonarjs/no-vue-bypass-sanitization": "off",
2199
+ "sonarjs/aws-iam-all-privileges": "error",
2200
+ "sonarjs/aws-rds-unencrypted-databases": "error",
2201
+ "sonarjs/aws-iam-all-resources-accessible": "off",
2202
+ "sonarjs/aws-opensearchservice-domain": "error",
2203
+ "sonarjs/aws-iam-privilege-escalation": "error",
2204
+ "sonarjs/aws-sagemaker-unencrypted-notebook": "error",
2205
+ "sonarjs/aws-restricted-ip-admin-access": "error",
2206
+ "sonarjs/no-empty-alternatives": "error",
2207
+ "sonarjs/no-regex-spaces": "error",
2208
+ "sonarjs/aws-sns-unencrypted-topics": "error",
2209
+ "sonarjs/existing-groups": "error",
2210
+ "sonarjs/aws-ec2-rds-dms-public": "error",
2211
+ "sonarjs/aws-sqs-unencrypted-queue": "error",
2212
+ "sonarjs/no-empty-group": "error",
2213
+ "sonarjs/aws-efs-unencrypted": "error",
2214
+ "sonarjs/aws-apigateway-public-api": "error",
2215
+ "sonarjs/stateful-regex": "error",
2216
+ "sonarjs/single-char-in-character-classes": "error",
2217
+ "sonarjs/no-exclusive-tests": "error",
2218
+ "sonarjs/hardcoded-secret-signatures": "error",
2219
+ "sonarjs/jsx-no-leaked-render": "error",
2220
+ "sonarjs/no-hook-setter-in-body": "error",
2221
+ "sonarjs/no-uniq-key": "error",
2222
+ "sonarjs/no-internal-api-use": "error",
2223
+ "sonarjs/no-literal-call": "error",
2224
+ "sonarjs/review-blockchain-mnemonic": "error",
2225
+ "sonarjs/dynamically-constructed-templates": "error",
2226
+ "sonarjs/no-duplicate-string": "off",
2227
+ "sonarjs/cognitive-complexity": "warn",
2228
+ "sonarjs/todo-tag": "warn",
2229
+ "sonarjs/no-hardcoded-passwords": "off",
2230
+ "sonarjs/no-alphabetical-sort": "off",
2231
+ "sonarjs/no-os-command-from-path": "off",
2232
+ "sonarjs/os-command": "off",
2233
+ "sonarjs/prefer-regexp-exec": "off",
2234
+ "sonarjs/no-clear-text-protocols": "off",
2235
+ "sonarjs/deprecation": "off",
2236
+ "sonarjs/no-nested-conditional": "off",
2237
+ "sonarjs/no-ignored-exceptions": "off",
2238
+ "sonarjs/slow-regex": "off",
2239
+ "sonarjs/prefer-read-only-props": "off",
2240
+ "sonarjs/no-skipped-tests": "off",
2241
+ "sonarjs/no-commented-code": "off",
2242
+ "sonarjs/no-ignored-return": "off",
2243
+ "sonarjs/array-callback-without-return": "off",
2244
+ "sonarjs/pseudo-random": "off",
2245
+ "sonarjs/no-nested-functions": "off",
2246
+ "sonarjs/no-async-constructor": "off",
2247
+ "sonarjs/assertions-in-tests": "off",
2248
+ "sonarjs/function-return-type": "off",
2249
+ "sonarjs/no-unused-vars": "off",
2250
+ "sonarjs/no-invariant-returns": "off",
2251
+ "sonarjs/different-types-comparison": "off",
2252
+ "sonarjs/no-selector-parameter": "off",
2253
+ "sonarjs/anchor-precedence": "off",
2254
+ "sonarjs/redundant-type-aliases": "off",
2255
+ "sonarjs/no-redundant-optional": "off",
2256
+ "sonarjs/reduce-initial-value": "off",
2257
+ "sonarjs/no-globals-shadowing": "off",
2258
+ "sonarjs/use-type-alias": "off",
2259
+ "sonarjs/void-use": "off",
2260
+ "sonarjs/no-undefined-argument": "off",
2261
+ "sonarjs/no-useless-react-setstate": "off",
2262
+ "sonarjs/no-inverted-boolean-check": "off",
2263
+ "sonarjs/concise-regex": "off",
2264
+ "sonarjs/no-dead-store": "off",
2265
+ "sonarjs/public-static-readonly": "off",
2266
+ "sonarjs/code-eval": "off",
2267
+ "sonarjs/no-misleading-array-reverse": "off",
2268
+ "sonarjs/fixme-tag": "off",
2269
+ "sonarjs/argument-type": "off",
2270
+ "sonarjs/constructor-for-side-effects": "off",
2271
+ "sonarjs/no-useless-intersection": "off",
2272
+ "sonarjs/no-empty-test-file": "off",
2273
+ "sonarjs/prefer-default-last": "off",
2274
+ "sonarjs/prefer-promise-shorthand": "off",
2275
+ "sonarjs/no-unsafe-unzip": "off",
2276
+ "sonarjs/no-nested-assignment": "off",
2277
+ "sonarjs/generator-without-yield": "off",
2278
+ "sonarjs/no-try-promise": "off",
2279
+ "sonarjs/single-character-alternation": "off",
2280
+ "sonarjs/class-name": "off",
2281
+ "sonarjs/no-hardcoded-secrets": "off",
2282
+ "sonarjs/regex-complexity": "off",
2283
+ "sonarjs/post-message": "off",
2284
+ "sonarjs/link-with-target-blank": "off",
2285
+ "sonarjs/duplicates-in-character-class": "off",
2286
+ "sonarjs/arguments-order": "off",
2287
+ "sonarjs/empty-string-repetition": "off",
2288
+ "sonarjs/table-header": "off",
2289
+ "sonarjs/no-implicit-global": "off",
2290
+ "sonarjs/no-control-regex": "off",
2291
+ },
2292
+ },
2293
+ {
2294
+ files: [
2295
+ "*.test.ts",
2296
+ "*.test.tsx",
2297
+ "*.spec.ts",
2298
+ ],
2299
+ rules: {
2300
+ "sonarjs/no-identical-functions": "off",
2301
+ },
2302
+ },
2303
+ {
2304
+ rules: {
2305
+ "no-caller": 2,
2306
+ "no-eval": 2,
2307
+ "no-delete-var": 2,
2308
+ "no-octal-escape": 2,
2309
+ },
2310
+ },
2311
+ {
2312
+ ignores: [
2313
+ "**/dist/**/*.*",
2314
+ "**/esm/**/*.*",
2315
+ "**/node_modules/**/*.*",
2316
+ "**/ci/results/**",
2317
+ "**/__version.ts",
2318
+ "**/cypress/results/**",
2319
+ "**/cypress/screenshots/**",
2320
+ "**/cypress/videos/**",
2321
+ "**/temp/**",
2322
+ "**/reference_workspace/**",
2323
+ ],
2324
+ },
2325
+ {
2326
+ rules: {
2327
+ curly: 0,
2328
+ "no-unexpected-multiline": 0,
2329
+ "@typescript-eslint/lines-around-comment": 0,
2330
+ "@typescript-eslint/quotes": 0,
2331
+ "unicorn/template-indent": 0,
2332
+ "@typescript-eslint/block-spacing": "off",
2333
+ "@typescript-eslint/brace-style": "off",
2334
+ "@typescript-eslint/comma-dangle": "off",
2335
+ "@typescript-eslint/comma-spacing": "off",
2336
+ "@typescript-eslint/func-call-spacing": "off",
2337
+ "@typescript-eslint/indent": "off",
2338
+ "@typescript-eslint/key-spacing": "off",
2339
+ "@typescript-eslint/keyword-spacing": "off",
2340
+ "@typescript-eslint/member-delimiter-style": "off",
2341
+ "@typescript-eslint/no-extra-parens": "off",
2342
+ "@typescript-eslint/no-extra-semi": "off",
2343
+ "@typescript-eslint/object-curly-spacing": "off",
2344
+ "@typescript-eslint/semi": "off",
2345
+ "@typescript-eslint/space-before-blocks": "off",
2346
+ "@typescript-eslint/space-before-function-paren": "off",
2347
+ "@typescript-eslint/space-infix-ops": "off",
2348
+ "@typescript-eslint/type-annotation-spacing": "off",
2349
+ "react/jsx-child-element-spacing": "off",
2350
+ "react/jsx-closing-bracket-location": "off",
2351
+ "react/jsx-closing-tag-location": "off",
2352
+ "react/jsx-curly-newline": "off",
2353
+ "react/jsx-curly-spacing": "off",
2354
+ "react/jsx-equals-spacing": "off",
2355
+ "react/jsx-first-prop-new-line": "off",
2356
+ "react/jsx-indent": "off",
2357
+ "react/jsx-indent-props": "off",
2358
+ "react/jsx-max-props-per-line": "off",
2359
+ "react/jsx-newline": "off",
2360
+ "react/jsx-one-expression-per-line": "off",
2361
+ "react/jsx-props-no-multi-spaces": "off",
2362
+ "react/jsx-tag-spacing": "off",
2363
+ "react/jsx-wrap-multilines": "off",
2364
+ "unicorn/empty-brace-spaces": "off",
2365
+ "unicorn/no-nested-ternary": "off",
2366
+ "unicorn/number-literal-case": "off",
2367
+ },
2368
+ },
2369
+ {
2370
+ languageOptions: {
2371
+ globals: { ...globals.browser },
2372
+ },
2373
+ },
2374
+ {
2375
+ languageOptions: {
2376
+ ecmaVersion: 2022,
2377
+ sourceType: "module",
2378
+ },
2379
+ },
2380
+ {
2381
+ plugins: {
2382
+ react: plugin0008,
2383
+ "react-hooks": plugin0009,
2384
+ },
2385
+ settings: {
2386
+ react: {
2387
+ version: "detect",
2388
+ },
2389
+ },
2390
+ rules: {
2391
+ "react/no-danger": "error",
2392
+ "react/prop-types": "off",
2393
+ "react/function-component-definition": [
2394
+ "error",
2395
+ {
2396
+ namedComponents: "function-declaration",
2397
+ unnamedComponents: "arrow-function",
2398
+ },
2399
+ ],
2400
+ "react/jsx-no-leaked-render": [
2401
+ "warn",
2402
+ {
2403
+ validStrategies: [
2404
+ "ternary",
2405
+ "coerce",
2406
+ ],
2407
+ },
2408
+ ],
2409
+ "react/jsx-boolean-value": [
2410
+ "error",
2411
+ "never",
2412
+ ],
2413
+ "react/react-in-jsx-scope": "off",
2414
+ "react-hooks/rules-of-hooks": "error",
2415
+ "react-hooks/exhaustive-deps": "error",
2416
+ },
2417
+ },
2418
+ {
2419
+ plugins: {
2420
+ "import-esm": plugin0010,
2421
+ },
2422
+ rules: {
2423
+ "import-esm/explicit-extension": "error",
2424
+ },
2425
+ },
2426
+ {
2427
+ plugins: {
2428
+ vitest: plugin0011,
2429
+ },
2430
+ rules: {
2431
+ "vitest/no-conditional-expect": "error",
2432
+ "vitest/no-import-node-test": "error",
2433
+ "vitest/no-interpolation-in-snapshots": "error",
2434
+ "vitest/no-mocks-import": "error",
2435
+ "vitest/no-standalone-expect": "error",
2436
+ "vitest/no-unneeded-async-expect-function": "error",
2437
+ "vitest/prefer-called-exactly-once-with": "error",
2438
+ "vitest/require-local-test-context-for-concurrent-snapshots": "error",
2439
+ "vitest/valid-describe-callback": "error",
2440
+ "vitest/expect-expect": "off",
2441
+ "vitest/no-commented-out-tests": "warn",
2442
+ "vitest/valid-title": "error",
2443
+ "vitest/no-disabled-tests": "warn",
2444
+ "vitest/no-focused-tests": "warn",
2445
+ "vitest/no-identical-title": "warn",
2446
+ "vitest/valid-expect": "warn",
2447
+ "vitest/valid-expect-in-promise": "error",
2448
+ },
2449
+ },
2450
+ {
2451
+ plugins: {
2452
+ "testing-library": plugin0012,
2453
+ },
2454
+ rules: {
2455
+ "testing-library/await-async-queries": "error",
2456
+ "testing-library/await-async-utils": "error",
2457
+ "testing-library/no-await-sync-queries": "error",
2458
+ "testing-library/no-global-regexp-flag-in-query": "error",
2459
+ "testing-library/no-node-access": "error",
2460
+ "testing-library/no-promise-in-fire-event": "error",
2461
+ "testing-library/no-wait-for-multiple-assertions": "error",
2462
+ "testing-library/no-wait-for-side-effects": "error",
2463
+ "testing-library/no-wait-for-snapshot": "error",
2464
+ "testing-library/prefer-find-by": "error",
2465
+ "testing-library/prefer-presence-queries": "error",
2466
+ "testing-library/prefer-query-by-disappearance": "error",
2467
+ "testing-library/prefer-screen-queries": "error",
2468
+ "testing-library/await-async-events": [
2469
+ "error",
2470
+ {
2471
+ eventModule: "userEvent",
2472
+ },
2473
+ ],
2474
+ "testing-library/no-await-sync-events": [
2475
+ "error",
2476
+ {
2477
+ eventModules: [
2478
+ "fire-event",
2479
+ ],
2480
+ },
2481
+ ],
2482
+ "testing-library/no-container": "error",
2483
+ "testing-library/no-debugging-utils": "warn",
2484
+ "testing-library/no-dom-import": [
2485
+ "error",
2486
+ "react",
2487
+ ],
2488
+ "testing-library/no-manual-cleanup": "error",
2489
+ "testing-library/no-render-in-lifecycle": "error",
2490
+ "testing-library/no-unnecessary-act": "error",
2491
+ "testing-library/render-result-naming-convention": "error",
2492
+ },
2493
+ },
2494
+ {
2495
+ plugins: {
2496
+ "no-only-tests": plugin0013,
2497
+ },
2498
+ rules: {
2499
+ "no-only-tests/no-only-tests": [
2500
+ "error",
2501
+ {
2502
+ block: [
2503
+ "fixture",
2504
+ ],
2505
+ focus: [
2506
+ "only",
2507
+ ],
2508
+ },
2509
+ ],
2510
+ },
2511
+ },
2512
+ ];