@gooddata/eslint-config 11.19.0-alpha.9 → 11.20.0-alpha.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.
Files changed (57) hide show
  1. package/PACKAGES_V8.md +1 -2
  2. package/PACKAGES_V9.md +1 -1
  3. package/PACKAGES_V9_OXLINT.md +21 -0
  4. package/README.md +22 -0
  5. package/dist/base.js +792 -283
  6. package/dist/base.json +1049 -213
  7. package/dist/browser-esm.js +794 -285
  8. package/dist/browser-esm.json +1051 -215
  9. package/dist/browser.js +792 -283
  10. package/dist/browser.json +1049 -213
  11. package/dist/esm-react-cypress.js +715 -187
  12. package/dist/esm-react-cypress.json +1051 -204
  13. package/dist/esm-react-vitest-storybook.js +825 -297
  14. package/dist/esm-react-vitest-storybook.json +1076 -204
  15. package/dist/esm-react-vitest.js +825 -297
  16. package/dist/esm-react-vitest.json +1060 -204
  17. package/dist/esm-react.js +798 -289
  18. package/dist/esm-react.json +1051 -216
  19. package/dist/esm-vitest.js +821 -293
  20. package/dist/esm-vitest.json +1060 -203
  21. package/dist/esm.js +794 -285
  22. package/dist/esm.json +1051 -215
  23. package/dist/oxlint-base.d.ts +12 -0
  24. package/dist/oxlint-base.js +1368 -0
  25. package/dist/oxlint-browser-esm.d.ts +12 -0
  26. package/dist/oxlint-browser-esm.js +1379 -0
  27. package/dist/oxlint-browser.d.ts +12 -0
  28. package/dist/oxlint-browser.js +1373 -0
  29. package/dist/oxlint-esm-react-cypress.d.ts +12 -0
  30. package/dist/oxlint-esm-react-cypress.js +1425 -0
  31. package/dist/oxlint-esm-react-vitest-storybook.d.ts +12 -0
  32. package/dist/oxlint-esm-react-vitest-storybook.js +1484 -0
  33. package/dist/oxlint-esm-react-vitest.d.ts +12 -0
  34. package/dist/oxlint-esm-react-vitest.js +1450 -0
  35. package/dist/oxlint-esm-react.d.ts +12 -0
  36. package/dist/oxlint-esm-react.js +1425 -0
  37. package/dist/oxlint-esm-vitest.d.ts +12 -0
  38. package/dist/oxlint-esm-vitest.js +1399 -0
  39. package/dist/oxlint-esm.d.ts +12 -0
  40. package/dist/oxlint-esm.js +1374 -0
  41. package/dist/oxlint-react-cypress.d.ts +12 -0
  42. package/dist/oxlint-react-cypress.js +1425 -0
  43. package/dist/oxlint-react-vitest.d.ts +12 -0
  44. package/dist/oxlint-react-vitest.js +1450 -0
  45. package/dist/oxlint-react.d.ts +12 -0
  46. package/dist/oxlint-react.js +1425 -0
  47. package/dist/oxlint-vitest.d.ts +12 -0
  48. package/dist/oxlint-vitest.js +1393 -0
  49. package/dist/react-cypress.js +713 -185
  50. package/dist/react-cypress.json +1050 -203
  51. package/dist/react-vitest.js +823 -295
  52. package/dist/react-vitest.json +1059 -203
  53. package/dist/react.js +796 -287
  54. package/dist/react.json +1049 -214
  55. package/dist/vitest.js +819 -291
  56. package/dist/vitest.json +1059 -202
  57. package/package.json +40 -6
@@ -3,50 +3,72 @@
3
3
  "header",
4
4
  "no-barrel-files",
5
5
  "import-x",
6
- "no-only-tests",
7
6
  "sonarjs",
8
7
  "react",
9
8
  "react-hooks",
10
9
  "import-esm",
11
- "@vitest"
12
- ],
13
- "extends": [
14
- "eslint:recommended",
15
- "plugin:import-x/recommended",
16
- "plugin:regexp/recommended",
17
- "plugin:sonarjs/recommended-legacy",
18
- "plugin:react-hooks/recommended-legacy",
19
- "plugin:import-esm/recommended",
20
- "plugin:@vitest/legacy-recommended"
10
+ "@vitest",
11
+ "no-only-tests"
21
12
  ],
22
13
  "rules": {
23
- "no-console": [
24
- 2,
25
- {
26
- "allow": [
27
- "warn",
28
- "error"
29
- ]
30
- }
31
- ],
32
- "no-restricted-exports": [
33
- 2,
34
- {
35
- "restrictDefaultExports": {
36
- "direct": true,
37
- "named": true,
38
- "defaultFrom": true,
39
- "namedFrom": true,
40
- "namespaceFrom": true
41
- }
42
- }
43
- ],
44
- "no-duplicate-imports": [
45
- "error",
46
- {
47
- "includeExports": true
48
- }
49
- ],
14
+ "constructor-super": "error",
15
+ "for-direction": "error",
16
+ "getter-return": "error",
17
+ "no-async-promise-executor": "error",
18
+ "no-case-declarations": "error",
19
+ "no-class-assign": "error",
20
+ "no-compare-neg-zero": "error",
21
+ "no-cond-assign": "error",
22
+ "no-const-assign": "error",
23
+ "no-constant-binary-expression": "error",
24
+ "no-constant-condition": "error",
25
+ "no-control-regex": "error",
26
+ "no-debugger": "error",
27
+ "no-delete-var": 2,
28
+ "no-dupe-args": "error",
29
+ "no-dupe-class-members": "error",
30
+ "no-dupe-else-if": "error",
31
+ "no-dupe-keys": "error",
32
+ "no-duplicate-case": "error",
33
+ "no-empty": "error",
34
+ "no-empty-character-class": "error",
35
+ "no-empty-pattern": "error",
36
+ "no-empty-static-block": "error",
37
+ "no-ex-assign": "error",
38
+ "no-fallthrough": "error",
39
+ "no-func-assign": "error",
40
+ "no-global-assign": "error",
41
+ "no-import-assign": "error",
42
+ "no-invalid-regexp": "error",
43
+ "no-irregular-whitespace": "error",
44
+ "no-loss-of-precision": "error",
45
+ "no-misleading-character-class": "error",
46
+ "no-new-native-nonconstructor": "error",
47
+ "no-nonoctal-decimal-escape": "error",
48
+ "no-obj-calls": "error",
49
+ "no-octal": "error",
50
+ "no-prototype-builtins": "error",
51
+ "no-redeclare": "error",
52
+ "no-regex-spaces": "error",
53
+ "no-self-assign": "error",
54
+ "no-setter-return": "error",
55
+ "no-shadow-restricted-names": "error",
56
+ "no-sparse-arrays": "error",
57
+ "no-this-before-super": "error",
58
+ "no-undef": "error",
59
+ "no-unreachable": "error",
60
+ "no-unsafe-finally": "error",
61
+ "no-unsafe-negation": "error",
62
+ "no-unsafe-optional-chaining": "error",
63
+ "no-unused-labels": "error",
64
+ "no-unused-private-class-members": "error",
65
+ "no-unused-vars": "error",
66
+ "no-useless-backreference": "error",
67
+ "no-useless-catch": "error",
68
+ "no-with": "error",
69
+ "require-yield": "error",
70
+ "use-isnan": "error",
71
+ "valid-typeof": "error",
50
72
  "no-restricted-imports": [
51
73
  "error",
52
74
  {
@@ -567,17 +589,6 @@
567
589
  ]
568
590
  }
569
591
  ],
570
- "no-restricted-syntax": [
571
- "error",
572
- {
573
- "selector": "MemberExpression[object.name='React']",
574
- "message": "Do not use `React.*`. Use named imports instead."
575
- },
576
- {
577
- "selector": "MemberExpression[object.name='ReactDOM']",
578
- "message": "Do not use `ReactDOM.*`. Use named imports instead."
579
- }
580
- ],
581
592
  "sort-imports": [
582
593
  "error",
583
594
  {
@@ -587,7 +598,6 @@
587
598
  }
588
599
  ],
589
600
  "no-useless-escape": "off",
590
- "no-negated-condition": "error",
591
601
  "no-unneeded-ternary": [
592
602
  "error",
593
603
  {
@@ -596,6 +606,46 @@
596
606
  ],
597
607
  "no-extra-boolean-cast": "error",
598
608
  "no-unexpected-multiline": 0,
609
+ "no-duplicate-imports": [
610
+ "error",
611
+ {
612
+ "includeExports": true
613
+ }
614
+ ],
615
+ "prefer-const": "off",
616
+ "no-console": [
617
+ 2,
618
+ {
619
+ "allow": [
620
+ "warn",
621
+ "error"
622
+ ]
623
+ }
624
+ ],
625
+ "no-restricted-exports": [
626
+ 2,
627
+ {
628
+ "restrictDefaultExports": {
629
+ "direct": true,
630
+ "named": true,
631
+ "defaultFrom": true,
632
+ "namedFrom": true,
633
+ "namespaceFrom": true
634
+ }
635
+ }
636
+ ],
637
+ "no-restricted-syntax": [
638
+ "error",
639
+ {
640
+ "selector": "MemberExpression[object.name='React']",
641
+ "message": "Do not use `React.*`. Use named imports instead."
642
+ },
643
+ {
644
+ "selector": "MemberExpression[object.name='ReactDOM']",
645
+ "message": "Do not use `ReactDOM.*`. Use named imports instead."
646
+ }
647
+ ],
648
+ "no-negated-condition": "error",
599
649
  "header/header": [
600
650
  2,
601
651
  "line",
@@ -605,6 +655,14 @@
605
655
  }
606
656
  ],
607
657
  "no-barrel-files/no-barrel-files": "error",
658
+ "import-x/named": "error",
659
+ "import-x/namespace": "error",
660
+ "import-x/default": "error",
661
+ "import-x/export": "error",
662
+ "import-x/no-named-as-default": "warn",
663
+ "import-x/no-named-as-default-member": "warn",
664
+ "import-x/no-duplicates": "warn",
665
+ "import-x/no-unassigned-import": "error",
608
666
  "import-x/order": [
609
667
  "error",
610
668
  {
@@ -640,20 +698,210 @@
640
698
  "newlines-between": "always"
641
699
  }
642
700
  ],
643
- "import-x/no-unassigned-import": "error",
644
- "no-only-tests/no-only-tests": [
645
- "error",
646
- {
647
- "block": [
648
- "fixture"
649
- ],
650
- "focus": [
651
- "only"
652
- ]
653
- }
654
- ],
655
- "regexp/prefer-d": "off",
656
- "regexp/prefer-w": "off",
701
+ "sonarjs/function-name": "off",
702
+ "sonarjs/max-lines": "off",
703
+ "sonarjs/no-tab": "off",
704
+ "sonarjs/variable-name": "off",
705
+ "sonarjs/comment-regex": "off",
706
+ "sonarjs/elseif-without-else": "off",
707
+ "sonarjs/no-fallthrough": "error",
708
+ "sonarjs/nested-control-flow": "off",
709
+ "sonarjs/too-many-break-or-continue-in-loop": "off",
710
+ "sonarjs/max-lines-per-function": "off",
711
+ "sonarjs/no-nested-incdec": "off",
712
+ "sonarjs/no-equals-in-for-termination": "error",
713
+ "sonarjs/no-extra-arguments": "error",
714
+ "sonarjs/no-collapsible-if": "off",
715
+ "sonarjs/expression-complexity": "off",
716
+ "sonarjs/no-redundant-parentheses": "off",
717
+ "sonarjs/no-labels": "error",
718
+ "sonarjs/no-redundant-boolean": "error",
719
+ "sonarjs/prefer-single-boolean-return": "error",
720
+ "sonarjs/unused-import": "error",
721
+ "sonarjs/useless-string-operation": "off",
722
+ "sonarjs/no-unused-function-argument": "off",
723
+ "sonarjs/no-case-label-in-switch": "error",
724
+ "sonarjs/no-parameter-reassignment": "error",
725
+ "sonarjs/prefer-while": "error",
726
+ "sonarjs/no-sonar-comments": "off",
727
+ "sonarjs/no-small-switch": "error",
728
+ "sonarjs/no-hardcoded-ip": "error",
729
+ "sonarjs/label-position": "error",
730
+ "sonarjs/file-header": "off",
731
+ "sonarjs/call-argument-line": "error",
732
+ "sonarjs/max-switch-cases": "error",
733
+ "sonarjs/prefer-immediate-return": "off",
734
+ "sonarjs/function-inside-loop": "error",
735
+ "sonarjs/no-variable-usage-before-declaration": "off",
736
+ "sonarjs/future-reserved-words": "error",
737
+ "sonarjs/array-constructor": "off",
738
+ "sonarjs/bitwise-operators": "error",
739
+ "sonarjs/no-function-declaration-in-block": "off",
740
+ "sonarjs/no-primitive-wrappers": "error",
741
+ "sonarjs/for-in": "off",
742
+ "sonarjs/cyclomatic-complexity": "off",
743
+ "sonarjs/no-identical-expressions": "error",
744
+ "sonarjs/no-nested-switch": "off",
745
+ "sonarjs/no-identical-conditions": "error",
746
+ "sonarjs/no-duplicated-branches": "error",
747
+ "sonarjs/misplaced-loop-counter": "error",
748
+ "sonarjs/sql-queries": "error",
749
+ "sonarjs/insecure-cookie": "error",
750
+ "sonarjs/no-useless-increment": "error",
751
+ "sonarjs/no-undefined-assignment": "off",
752
+ "sonarjs/no-wildcard-import": "off",
753
+ "sonarjs/for-loop-increment-sign": "error",
754
+ "sonarjs/cookies": "off",
755
+ "sonarjs/null-dereference": "error",
756
+ "sonarjs/updated-loop-counter": "error",
757
+ "sonarjs/block-scoped-var": "error",
758
+ "sonarjs/no-built-in-override": "off",
759
+ "sonarjs/prefer-object-literal": "off",
760
+ "sonarjs/no-gratuitous-expressions": "error",
761
+ "sonarjs/file-uploads": "error",
762
+ "sonarjs/file-permissions": "error",
763
+ "sonarjs/no-empty-character-class": "error",
764
+ "sonarjs/no-unenclosed-multiline-block": "error",
765
+ "sonarjs/index-of-compare-to-positive-number": "error",
766
+ "sonarjs/no-useless-catch": "error",
767
+ "sonarjs/xml-parser-xxe": "error",
768
+ "sonarjs/non-existent-operator": "error",
769
+ "sonarjs/web-sql-database": "off",
770
+ "sonarjs/no-array-delete": "error",
771
+ "sonarjs/no-incomplete-assertions": "error",
772
+ "sonarjs/no-global-this": "error",
773
+ "sonarjs/new-operator-misuse": "error",
774
+ "sonarjs/no-delete-var": "error",
775
+ "sonarjs/strings-comparison": "off",
776
+ "sonarjs/file-name-differ-from-class": "off",
777
+ "sonarjs/cookie-no-httponly": "error",
778
+ "sonarjs/no-incorrect-string-concat": "off",
779
+ "sonarjs/inverted-assertion-arguments": "error",
780
+ "sonarjs/shorthand-property-grouping": "off",
781
+ "sonarjs/updated-const-var": "error",
782
+ "sonarjs/arguments-usage": "off",
783
+ "sonarjs/destructuring-assignment-syntax": "off",
784
+ "sonarjs/arrow-function-convention": "off",
785
+ "sonarjs/class-prototype": "off",
786
+ "sonarjs/no-require-or-define": "off",
787
+ "sonarjs/no-associative-arrays": "error",
788
+ "sonarjs/comma-or-logical-or-case": "error",
789
+ "sonarjs/no-redundant-jump": "error",
790
+ "sonarjs/inconsistent-function-call": "error",
791
+ "sonarjs/no-use-of-empty-return-value": "error",
792
+ "sonarjs/enforce-trailing-comma": "off",
793
+ "sonarjs/operation-returning-nan": "off",
794
+ "sonarjs/values-not-convertible-to-numbers": "off",
795
+ "sonarjs/non-number-in-arithmetic-expression": "off",
796
+ "sonarjs/in-operator-type-error": "error",
797
+ "sonarjs/declarations-in-global-scope": "off",
798
+ "sonarjs/no-inconsistent-returns": "off",
799
+ "sonarjs/no-reference-error": "off",
800
+ "sonarjs/super-invocation": "error",
801
+ "sonarjs/no-all-duplicated-branches": "error",
802
+ "sonarjs/no-same-line-conditional": "error",
803
+ "sonarjs/conditional-indentation": "off",
804
+ "sonarjs/no-collection-size-mischeck": "error",
805
+ "sonarjs/no-unthrown-error": "error",
806
+ "sonarjs/no-unused-collection": "error",
807
+ "sonarjs/no-for-in-iterable": "off",
808
+ "sonarjs/no-element-overwrite": "error",
809
+ "sonarjs/no-identical-functions": "error",
810
+ "sonarjs/no-empty-collection": "error",
811
+ "sonarjs/no-redundant-assignments": "error",
812
+ "sonarjs/prefer-type-guard": "error",
813
+ "sonarjs/no-return-type-any": "off",
814
+ "sonarjs/no-implicit-dependencies": "off",
815
+ "sonarjs/weak-ssl": "error",
816
+ "sonarjs/no-weak-keys": "error",
817
+ "sonarjs/csrf": "error",
818
+ "sonarjs/production-debug": "error",
819
+ "sonarjs/no-in-misuse": "error",
820
+ "sonarjs/no-duplicate-in-composite": "error",
821
+ "sonarjs/max-union-size": "off",
822
+ "sonarjs/no-nested-template-literals": "error",
823
+ "sonarjs/regular-expr": "off",
824
+ "sonarjs/encryption": "off",
825
+ "sonarjs/hashing": "error",
826
+ "sonarjs/bool-param-default": "off",
827
+ "sonarjs/xpath": "off",
828
+ "sonarjs/sockets": "off",
829
+ "sonarjs/process-argv": "off",
830
+ "sonarjs/standard-input": "off",
831
+ "sonarjs/unverified-certificate": "error",
832
+ "sonarjs/cors": "error",
833
+ "sonarjs/disabled-auto-escaping": "error",
834
+ "sonarjs/no-table-as-layout": "error",
835
+ "sonarjs/table-header-reference": "error",
836
+ "sonarjs/object-alt-content": "error",
837
+ "sonarjs/publicly-writable-directories": "error",
838
+ "sonarjs/unverified-hostname": "error",
839
+ "sonarjs/encryption-secure-mode": "error",
840
+ "sonarjs/no-weak-cipher": "error",
841
+ "sonarjs/no-intrusive-permissions": "error",
842
+ "sonarjs/insecure-jwt-token": "error",
843
+ "sonarjs/x-powered-by": "error",
844
+ "sonarjs/hidden-files": "error",
845
+ "sonarjs/content-length": "error",
846
+ "sonarjs/disabled-resource-integrity": "error",
847
+ "sonarjs/content-security-policy": "error",
848
+ "sonarjs/no-mixed-content": "error",
849
+ "sonarjs/frame-ancestors": "error",
850
+ "sonarjs/no-mime-sniff": "error",
851
+ "sonarjs/no-referrer-policy": "error",
852
+ "sonarjs/strict-transport-security": "error",
853
+ "sonarjs/certificate-transparency": "off",
854
+ "sonarjs/dns-prefetching": "off",
855
+ "sonarjs/confidential-information-logging": "error",
856
+ "sonarjs/no-ip-forward": "error",
857
+ "sonarjs/no-invalid-regexp": "error",
858
+ "sonarjs/unused-named-groups": "error",
859
+ "sonarjs/no-same-argument-assert": "error",
860
+ "sonarjs/unicode-aware-regex": "off",
861
+ "sonarjs/no-misleading-character-class": "error",
862
+ "sonarjs/session-regeneration": "error",
863
+ "sonarjs/test-check-exception": "error",
864
+ "sonarjs/stable-tests": "error",
865
+ "sonarjs/no-empty-after-reluctant": "error",
866
+ "sonarjs/no-code-after-done": "error",
867
+ "sonarjs/disabled-timeout": "error",
868
+ "sonarjs/chai-determinate-assertion": "error",
869
+ "sonarjs/aws-s3-bucket-server-encryption": "off",
870
+ "sonarjs/aws-s3-bucket-insecure-http": "error",
871
+ "sonarjs/aws-s3-bucket-versioning": "error",
872
+ "sonarjs/aws-s3-bucket-granted-access": "error",
873
+ "sonarjs/no-angular-bypass-sanitization": "error",
874
+ "sonarjs/aws-iam-public-access": "error",
875
+ "sonarjs/aws-ec2-unencrypted-ebs-volume": "error",
876
+ "sonarjs/aws-s3-bucket-public-access": "error",
877
+ "sonarjs/no-vue-bypass-sanitization": "off",
878
+ "sonarjs/aws-iam-all-privileges": "error",
879
+ "sonarjs/aws-rds-unencrypted-databases": "error",
880
+ "sonarjs/aws-iam-all-resources-accessible": "off",
881
+ "sonarjs/aws-opensearchservice-domain": "error",
882
+ "sonarjs/aws-iam-privilege-escalation": "error",
883
+ "sonarjs/aws-sagemaker-unencrypted-notebook": "error",
884
+ "sonarjs/aws-restricted-ip-admin-access": "error",
885
+ "sonarjs/no-empty-alternatives": "error",
886
+ "sonarjs/no-regex-spaces": "error",
887
+ "sonarjs/aws-sns-unencrypted-topics": "error",
888
+ "sonarjs/existing-groups": "error",
889
+ "sonarjs/aws-ec2-rds-dms-public": "error",
890
+ "sonarjs/aws-sqs-unencrypted-queue": "error",
891
+ "sonarjs/no-empty-group": "error",
892
+ "sonarjs/aws-efs-unencrypted": "error",
893
+ "sonarjs/aws-apigateway-public-api": "error",
894
+ "sonarjs/stateful-regex": "error",
895
+ "sonarjs/single-char-in-character-classes": "error",
896
+ "sonarjs/no-exclusive-tests": "error",
897
+ "sonarjs/hardcoded-secret-signatures": "error",
898
+ "sonarjs/jsx-no-leaked-render": "error",
899
+ "sonarjs/no-hook-setter-in-body": "error",
900
+ "sonarjs/no-uniq-key": "error",
901
+ "sonarjs/no-internal-api-use": "error",
902
+ "sonarjs/no-literal-call": "error",
903
+ "sonarjs/review-blockchain-mnemonic": "error",
904
+ "sonarjs/dynamically-constructed-templates": "error",
657
905
  "sonarjs/no-duplicate-string": "off",
658
906
  "sonarjs/cognitive-complexity": "warn",
659
907
  "sonarjs/todo-tag": "warn",
@@ -721,7 +969,6 @@
721
969
  "sonarjs/no-control-regex": "off",
722
970
  "no-caller": 2,
723
971
  "no-eval": 2,
724
- "no-delete-var": 2,
725
972
  "no-octal-escape": 2,
726
973
  "curly": 0,
727
974
  "@typescript-eslint/lines-around-comment": 0,
@@ -787,13 +1034,35 @@
787
1034
  "react/react-in-jsx-scope": "off",
788
1035
  "react-hooks/rules-of-hooks": "error",
789
1036
  "react-hooks/exhaustive-deps": "error",
1037
+ "import-esm/explicit-extension": "error",
1038
+ "@vitest/no-conditional-expect": "error",
1039
+ "@vitest/no-import-node-test": "error",
1040
+ "@vitest/no-interpolation-in-snapshots": "error",
1041
+ "@vitest/no-mocks-import": "error",
1042
+ "@vitest/no-standalone-expect": "error",
1043
+ "@vitest/no-unneeded-async-expect-function": "error",
1044
+ "@vitest/prefer-called-exactly-once-with": "error",
1045
+ "@vitest/require-local-test-context-for-concurrent-snapshots": "error",
1046
+ "@vitest/valid-describe-callback": "error",
1047
+ "@vitest/valid-expect-in-promise": "error",
790
1048
  "@vitest/expect-expect": "off",
791
1049
  "@vitest/no-commented-out-tests": "warn",
792
1050
  "@vitest/valid-title": "error",
793
1051
  "@vitest/no-disabled-tests": "warn",
794
1052
  "@vitest/no-focused-tests": "warn",
795
1053
  "@vitest/no-identical-title": "warn",
796
- "@vitest/valid-expect": "warn"
1054
+ "@vitest/valid-expect": "warn",
1055
+ "no-only-tests/no-only-tests": [
1056
+ "error",
1057
+ {
1058
+ "block": [
1059
+ "fixture"
1060
+ ],
1061
+ "focus": [
1062
+ "only"
1063
+ ]
1064
+ }
1065
+ ]
797
1066
  },
798
1067
  "overrides": [
799
1068
  {
@@ -801,18 +1070,6 @@
801
1070
  "**/*.ts",
802
1071
  "**/*.tsx"
803
1072
  ],
804
- "excludedFiles": [
805
- "**/vitest.config.ts",
806
- "**/vitest.*.config.ts",
807
- "**/vitest.setup.ts",
808
- "**/vitest.setup.tsx",
809
- "**/*.test.ts",
810
- "**/*.test.tsx",
811
- "**/*.test.utils.ts",
812
- "**/*.test.utils.tsx",
813
- "**/*.test.helpers.ts",
814
- "**/*.test.helpers.tsx"
815
- ],
816
1073
  "rules": {
817
1074
  "no-restricted-imports": [
818
1075
  "error",
@@ -1344,139 +1601,747 @@
1344
1601
  },
1345
1602
  {
1346
1603
  "files": [
1347
- "**/eslint.config.ts",
1348
- "**/eslint.config.js"
1349
- ],
1350
- "rules": {
1351
- "no-restricted-exports": "off"
1352
- }
1353
- },
1354
- {
1355
- "parser": "@typescript-eslint/parser",
1356
- "files": [
1357
- "**/*.ts",
1358
- "**/*.tsx",
1359
- "**/*.mts",
1360
- "**/*.cts"
1361
- ],
1362
- "extends": [
1363
- "plugin:@typescript-eslint/recommended-type-checked"
1604
+ "**/vitest.config.ts",
1605
+ "**/vitest.*.config.ts",
1606
+ "**/vitest.setup.ts",
1607
+ "**/vitest.setup.tsx",
1608
+ "**/*.test.ts",
1609
+ "**/*.test.tsx",
1610
+ "**/*.test.utils.ts",
1611
+ "**/*.test.utils.tsx",
1612
+ "**/*.test.helpers.ts",
1613
+ "**/*.test.helpers.tsx"
1364
1614
  ],
1365
- "parserOptions": {
1366
- "ecmaVersion": 2022,
1367
- "sourceType": "module",
1368
- "projectService": true
1369
- },
1370
1615
  "rules": {
1371
- "@typescript-eslint/explicit-function-return-type": 0,
1372
- "@typescript-eslint/no-use-before-define": 0,
1373
- "@typescript-eslint/no-empty-function": 0,
1374
- "@typescript-eslint/naming-convention": [
1375
- "error",
1376
- {
1377
- "selector": "interface",
1378
- "format": [
1379
- "PascalCase"
1380
- ],
1381
- "custom": {
1382
- "regex": "^I[A-Z]",
1383
- "match": true
1384
- }
1385
- }
1386
- ],
1387
- "@typescript-eslint/no-unused-vars": [
1388
- 2,
1389
- {
1390
- "varsIgnorePattern": "^_.*$",
1391
- "argsIgnorePattern": "^_.*$"
1392
- }
1393
- ],
1394
- "@typescript-eslint/no-explicit-any": "error",
1395
- "@typescript-eslint/array-type": "off",
1396
- "@typescript-eslint/ban-ts-comment": [
1397
- "error",
1398
- {
1399
- "ts-expect-error": "allow-with-description"
1400
- }
1401
- ],
1402
- "@typescript-eslint/no-wrapper-object-types": "error",
1403
- "@typescript-eslint/no-unsafe-function-type": "error",
1404
- "@typescript-eslint/no-restricted-types": [
1616
+ "no-restricted-imports": [
1405
1617
  "error",
1406
1618
  {
1407
- "types": {
1408
- "String": {
1409
- "message": "Use 'string' instead",
1410
- "fixWith": "string"
1619
+ "paths": [
1620
+ {
1621
+ "name": "react",
1622
+ "importNames": [
1623
+ "default"
1624
+ ],
1625
+ "message": "Default import from React is not allowed. Use named imports instead."
1411
1626
  },
1412
- "Number": {
1413
- "message": "Use 'number' instead",
1414
- "fixWith": "number"
1627
+ {
1628
+ "name": "react-dom",
1629
+ "importNames": [
1630
+ "default"
1631
+ ],
1632
+ "message": "Default import from React DOM is not allowed. Use named imports instead."
1415
1633
  },
1416
- "Boolean": {
1417
- "message": "Use 'boolean' instead",
1418
- "fixWith": "boolean"
1634
+ {
1635
+ "name": "@gooddata/sdk-ui-kit",
1636
+ "importNames": [
1637
+ "Icon"
1638
+ ],
1639
+ "message": "The Icon export cannot be tree-shaken, use {IconName}Icon imports instead."
1419
1640
  },
1420
- "Symbol": {
1421
- "message": "Use 'symbol' instead",
1422
- "fixWith": "symbol"
1641
+ {
1642
+ "name": "vitest",
1643
+ "importNames": [
1644
+ "test"
1645
+ ],
1646
+ "message": "Use 'it' instead of 'test' for consistency."
1423
1647
  }
1424
- }
1425
- }
1426
- ],
1427
- "@typescript-eslint/consistent-type-exports": [
1428
- "error",
1429
- {
1430
- "fixMixedExportsWithInlineTypeSpecifier": false
1431
- }
1432
- ],
1433
- "@typescript-eslint/explicit-member-accessibility": "off",
1434
- "@typescript-eslint/interface-name-prefix": "off",
1435
- "@typescript-eslint/member-ordering": "off",
1436
- "@typescript-eslint/no-inferrable-types": "off",
1437
- "@typescript-eslint/no-non-null-assertion": "off",
1438
- "@typescript-eslint/prefer-optional-chain": "error",
1439
- "no-restricted-syntax": [
1440
- "error",
1441
- {
1442
- "selector": "MemberExpression[object.name='React']",
1443
- "message": "Do not use `React.*`. Use named imports instead."
1444
- },
1445
- {
1446
- "selector": "TSTypeReference[typeName.type='TSQualifiedName'][typeName.left.name='React']",
1447
- "message": "Do not use `React.*` types. Use named imports instead."
1448
- },
1449
- {
1450
- "selector": "ExportNamespaceSpecifier",
1451
- "message": "Usage of 'export * as …' is forbidden."
1452
- },
1453
- {
1454
- "selector": "ExportAllDeclaration",
1455
- "message": "Usage of `export * from` is forbidden."
1456
- },
1457
- {
1458
- "selector": "ImportDeclaration[source.value=/^(?!.*reference_workspace)\\./] ImportNamespaceSpecifier",
1459
- "message": "Do not use `import * as ...` from relative paths."
1460
- }
1461
- ],
1648
+ ],
1649
+ "patterns": [
1650
+ {
1651
+ "group": [
1652
+ "lodash-es"
1653
+ ],
1654
+ "importNames": [
1655
+ "get",
1656
+ "getOr"
1657
+ ],
1658
+ "message": "Please use the ?. and ?? operators instead."
1659
+ },
1660
+ {
1661
+ "group": [
1662
+ "lodash-es"
1663
+ ],
1664
+ "importNames": [
1665
+ "keys"
1666
+ ],
1667
+ "message": "Please use Object.keys() instead."
1668
+ },
1669
+ {
1670
+ "group": [
1671
+ "lodash-es"
1672
+ ],
1673
+ "importNames": [
1674
+ "values"
1675
+ ],
1676
+ "message": "Please use Object.values() instead."
1677
+ },
1678
+ {
1679
+ "group": [
1680
+ "lodash-es"
1681
+ ],
1682
+ "importNames": [
1683
+ "entries",
1684
+ "toPairs"
1685
+ ],
1686
+ "message": "Please use Object.entries() instead."
1687
+ },
1688
+ {
1689
+ "group": [
1690
+ "lodash-es"
1691
+ ],
1692
+ "importNames": [
1693
+ "map"
1694
+ ],
1695
+ "message": "Please use Array.prototype.map() instead."
1696
+ },
1697
+ {
1698
+ "group": [
1699
+ "lodash-es"
1700
+ ],
1701
+ "importNames": [
1702
+ "flatMap"
1703
+ ],
1704
+ "message": "Please use Array.prototype.flatMap() instead."
1705
+ },
1706
+ {
1707
+ "group": [
1708
+ "lodash-es"
1709
+ ],
1710
+ "importNames": [
1711
+ "filter"
1712
+ ],
1713
+ "message": "Please use Array.prototype.filter() instead."
1714
+ },
1715
+ {
1716
+ "group": [
1717
+ "lodash-es"
1718
+ ],
1719
+ "importNames": [
1720
+ "find"
1721
+ ],
1722
+ "message": "Please use Array.prototype.find() instead."
1723
+ },
1724
+ {
1725
+ "group": [
1726
+ "lodash-es"
1727
+ ],
1728
+ "importNames": [
1729
+ "findIndex"
1730
+ ],
1731
+ "message": "Please use Array.prototype.findIndex() instead."
1732
+ },
1733
+ {
1734
+ "group": [
1735
+ "lodash-es"
1736
+ ],
1737
+ "importNames": [
1738
+ "includes"
1739
+ ],
1740
+ "message": "Please use Array.prototype.includes() instead."
1741
+ },
1742
+ {
1743
+ "group": [
1744
+ "lodash-es"
1745
+ ],
1746
+ "importNames": [
1747
+ "some"
1748
+ ],
1749
+ "message": "Please use Array.prototype.some() instead."
1750
+ },
1751
+ {
1752
+ "group": [
1753
+ "lodash-es"
1754
+ ],
1755
+ "importNames": [
1756
+ "every"
1757
+ ],
1758
+ "message": "Please use Array.prototype.every() instead."
1759
+ },
1760
+ {
1761
+ "group": [
1762
+ "lodash-es"
1763
+ ],
1764
+ "importNames": [
1765
+ "concat"
1766
+ ],
1767
+ "message": "Please use Array.prototype.concat() or spread [...arr1, ...arr2] instead."
1768
+ },
1769
+ {
1770
+ "group": [
1771
+ "lodash-es"
1772
+ ],
1773
+ "importNames": [
1774
+ "reverse"
1775
+ ],
1776
+ "message": "Please use Array.prototype.reverse() instead."
1777
+ },
1778
+ {
1779
+ "group": [
1780
+ "lodash-es"
1781
+ ],
1782
+ "importNames": [
1783
+ "slice"
1784
+ ],
1785
+ "message": "Please use Array.prototype.slice() instead."
1786
+ },
1787
+ {
1788
+ "group": [
1789
+ "lodash-es"
1790
+ ],
1791
+ "importNames": [
1792
+ "indexOf"
1793
+ ],
1794
+ "message": "Please use Array.prototype.indexOf() instead."
1795
+ },
1796
+ {
1797
+ "group": [
1798
+ "lodash-es"
1799
+ ],
1800
+ "importNames": [
1801
+ "lastIndexOf"
1802
+ ],
1803
+ "message": "Please use Array.prototype.lastIndexOf() instead."
1804
+ },
1805
+ {
1806
+ "group": [
1807
+ "lodash-es"
1808
+ ],
1809
+ "importNames": [
1810
+ "fill"
1811
+ ],
1812
+ "message": "Please use Array.prototype.fill() instead."
1813
+ },
1814
+ {
1815
+ "group": [
1816
+ "lodash-es"
1817
+ ],
1818
+ "importNames": [
1819
+ "startsWith"
1820
+ ],
1821
+ "message": "Please use String.prototype.startsWith() instead."
1822
+ },
1823
+ {
1824
+ "group": [
1825
+ "lodash-es"
1826
+ ],
1827
+ "importNames": [
1828
+ "endsWith"
1829
+ ],
1830
+ "message": "Please use String.prototype.endsWith() instead."
1831
+ },
1832
+ {
1833
+ "group": [
1834
+ "lodash-es"
1835
+ ],
1836
+ "importNames": [
1837
+ "repeat"
1838
+ ],
1839
+ "message": "Please use String.prototype.repeat() instead."
1840
+ },
1841
+ {
1842
+ "group": [
1843
+ "lodash-es"
1844
+ ],
1845
+ "importNames": [
1846
+ "padStart"
1847
+ ],
1848
+ "message": "Please use String.prototype.padStart() instead."
1849
+ },
1850
+ {
1851
+ "group": [
1852
+ "lodash-es"
1853
+ ],
1854
+ "importNames": [
1855
+ "padEnd"
1856
+ ],
1857
+ "message": "Please use String.prototype.padEnd() instead."
1858
+ },
1859
+ {
1860
+ "group": [
1861
+ "lodash-es"
1862
+ ],
1863
+ "importNames": [
1864
+ "trim"
1865
+ ],
1866
+ "message": "Please use String.prototype.trim() instead."
1867
+ },
1868
+ {
1869
+ "group": [
1870
+ "lodash-es"
1871
+ ],
1872
+ "importNames": [
1873
+ "trimStart",
1874
+ "trimLeft"
1875
+ ],
1876
+ "message": "Please use String.prototype.trimStart() instead."
1877
+ },
1878
+ {
1879
+ "group": [
1880
+ "lodash-es"
1881
+ ],
1882
+ "importNames": [
1883
+ "trimEnd",
1884
+ "trimRight"
1885
+ ],
1886
+ "message": "Please use String.prototype.trimEnd() instead."
1887
+ },
1888
+ {
1889
+ "group": [
1890
+ "lodash-es"
1891
+ ],
1892
+ "importNames": [
1893
+ "toUpper"
1894
+ ],
1895
+ "message": "Please use String.prototype.toUpperCase() instead."
1896
+ },
1897
+ {
1898
+ "group": [
1899
+ "lodash-es"
1900
+ ],
1901
+ "importNames": [
1902
+ "toLower"
1903
+ ],
1904
+ "message": "Please use String.prototype.toLowerCase() instead."
1905
+ },
1906
+ {
1907
+ "group": [
1908
+ "lodash-es"
1909
+ ],
1910
+ "importNames": [
1911
+ "isArray"
1912
+ ],
1913
+ "message": "Please use Array.isArray() instead."
1914
+ },
1915
+ {
1916
+ "group": [
1917
+ "lodash-es"
1918
+ ],
1919
+ "importNames": [
1920
+ "isNaN"
1921
+ ],
1922
+ "message": "Please use Number.isNaN() instead."
1923
+ },
1924
+ {
1925
+ "group": [
1926
+ "lodash-es"
1927
+ ],
1928
+ "importNames": [
1929
+ "isFinite"
1930
+ ],
1931
+ "message": "Please use Number.isFinite() instead."
1932
+ },
1933
+ {
1934
+ "group": [
1935
+ "lodash-es"
1936
+ ],
1937
+ "importNames": [
1938
+ "isInteger"
1939
+ ],
1940
+ "message": "Please use Number.isInteger() instead."
1941
+ },
1942
+ {
1943
+ "group": [
1944
+ "lodash-es"
1945
+ ],
1946
+ "importNames": [
1947
+ "isNull"
1948
+ ],
1949
+ "message": "Please use value === null instead."
1950
+ },
1951
+ {
1952
+ "group": [
1953
+ "lodash-es"
1954
+ ],
1955
+ "importNames": [
1956
+ "isUndefined"
1957
+ ],
1958
+ "message": "Please use value === undefined instead."
1959
+ },
1960
+ {
1961
+ "group": [
1962
+ "lodash-es"
1963
+ ],
1964
+ "importNames": [
1965
+ "defaultTo"
1966
+ ],
1967
+ "message": "Please use value ?? defaultValue instead."
1968
+ },
1969
+ {
1970
+ "group": [
1971
+ "lodash-es"
1972
+ ],
1973
+ "importNames": [
1974
+ "assign"
1975
+ ],
1976
+ "message": "Please use Object.assign() or spread syntax {...obj} instead."
1977
+ },
1978
+ {
1979
+ "group": [
1980
+ "lodash-es"
1981
+ ],
1982
+ "importNames": [
1983
+ "flatten"
1984
+ ],
1985
+ "message": "Please use Array.prototype.flat() instead."
1986
+ },
1987
+ {
1988
+ "group": [
1989
+ "lodash-es"
1990
+ ],
1991
+ "importNames": [
1992
+ "flattenDeep"
1993
+ ],
1994
+ "message": "Please use Array.prototype.flat(Infinity) instead."
1995
+ },
1996
+ {
1997
+ "group": [
1998
+ "lodash-es"
1999
+ ],
2000
+ "importNames": [
2001
+ "isNil"
2002
+ ],
2003
+ "message": "Please use value === null || value === undefined instead."
2004
+ },
2005
+ {
2006
+ "group": [
2007
+ "lodash-es"
2008
+ ],
2009
+ "importNames": [
2010
+ "noop"
2011
+ ],
2012
+ "message": "Please use () => {} instead."
2013
+ },
2014
+ {
2015
+ "group": [
2016
+ "lodash-es"
2017
+ ],
2018
+ "importNames": [
2019
+ "identity"
2020
+ ],
2021
+ "message": "Please use x => x instead."
2022
+ },
2023
+ {
2024
+ "group": [
2025
+ "lodash-es"
2026
+ ],
2027
+ "importNames": [
2028
+ "first",
2029
+ "head"
2030
+ ],
2031
+ "message": "Please use Array.prototype.at(0) instead."
2032
+ },
2033
+ {
2034
+ "group": [
2035
+ "lodash-es"
2036
+ ],
2037
+ "importNames": [
2038
+ "last"
2039
+ ],
2040
+ "message": "Please use Array.prototype.at(-1) instead."
2041
+ },
2042
+ {
2043
+ "group": [
2044
+ "lodash-es"
2045
+ ],
2046
+ "importNames": [
2047
+ "forEach"
2048
+ ],
2049
+ "message": "Please use Array.prototype.forEach() instead."
2050
+ },
2051
+ {
2052
+ "group": [
2053
+ "lodash-es"
2054
+ ],
2055
+ "importNames": [
2056
+ "fromPairs"
2057
+ ],
2058
+ "message": "Please use Object.fromEntries() instead."
2059
+ },
2060
+ {
2061
+ "group": [
2062
+ "lodash-es"
2063
+ ],
2064
+ "importNames": [
2065
+ "join"
2066
+ ],
2067
+ "message": "Please use Array.prototype.join() instead."
2068
+ },
2069
+ {
2070
+ "group": [
2071
+ "lodash-es"
2072
+ ],
2073
+ "importNames": [
2074
+ "isDate"
2075
+ ],
2076
+ "message": "Please use val instanceof Date instead."
2077
+ },
2078
+ {
2079
+ "group": [
2080
+ "lodash-es"
2081
+ ],
2082
+ "importNames": [
2083
+ "isFunction"
2084
+ ],
2085
+ "message": "Please use typeof val === 'function' instead."
2086
+ },
2087
+ {
2088
+ "group": [
2089
+ "lodash-es"
2090
+ ],
2091
+ "importNames": [
2092
+ "isNumber"
2093
+ ],
2094
+ "message": "Please use typeof val === 'number' instead."
2095
+ },
2096
+ {
2097
+ "group": [
2098
+ "lodash-es"
2099
+ ],
2100
+ "importNames": [
2101
+ "isObject"
2102
+ ],
2103
+ "message": "Please use val !== null && typeof val === 'object' instead."
2104
+ },
2105
+ {
2106
+ "group": [
2107
+ "lodash-es"
2108
+ ],
2109
+ "importNames": [
2110
+ "isString"
2111
+ ],
2112
+ "message": "Please use typeof val === 'string' instead."
2113
+ },
2114
+ {
2115
+ "group": [
2116
+ "lodash-es"
2117
+ ],
2118
+ "importNames": [
2119
+ "toString"
2120
+ ],
2121
+ "message": "Please use String(val) instead."
2122
+ },
2123
+ {
2124
+ "group": [
2125
+ "lodash-es"
2126
+ ],
2127
+ "importNames": [
2128
+ "flow",
2129
+ "flowRight"
2130
+ ],
2131
+ "message": "Please use refactoring your code instead."
2132
+ }
2133
+ ]
2134
+ }
2135
+ ]
2136
+ }
2137
+ },
2138
+ {
2139
+ "files": [
2140
+ "**/eslint.config.ts",
2141
+ "**/eslint.config.js"
2142
+ ],
2143
+ "rules": {
2144
+ "no-restricted-exports": "off"
2145
+ }
2146
+ },
2147
+ {
2148
+ "files": [
2149
+ "**/*.ts",
2150
+ "**/*.tsx",
2151
+ "**/*.mts",
2152
+ "**/*.cts"
2153
+ ],
2154
+ "rules": {
2155
+ "constructor-super": "off",
2156
+ "getter-return": "off",
2157
+ "no-class-assign": "off",
2158
+ "no-const-assign": "off",
2159
+ "no-dupe-args": "off",
2160
+ "no-dupe-class-members": "off",
2161
+ "no-dupe-keys": "off",
2162
+ "no-func-assign": "off",
2163
+ "no-import-assign": "off",
2164
+ "no-new-native-nonconstructor": "off",
2165
+ "no-new-symbol": "off",
2166
+ "no-obj-calls": "off",
2167
+ "no-redeclare": "off",
2168
+ "no-setter-return": "off",
2169
+ "no-this-before-super": "off",
2170
+ "no-undef": "off",
2171
+ "no-unreachable": "off",
2172
+ "no-unsafe-negation": "off",
2173
+ "no-var": "error",
2174
+ "no-with": "off",
2175
+ "prefer-const": "error",
2176
+ "prefer-rest-params": "error",
2177
+ "prefer-spread": "error",
2178
+ "no-array-constructor": "off",
2179
+ "no-unused-expressions": "off",
2180
+ "no-unused-vars": "off",
2181
+ "@typescript-eslint/no-array-constructor": "error",
2182
+ "@typescript-eslint/no-duplicate-enum-values": "error",
2183
+ "@typescript-eslint/no-empty-object-type": "error",
2184
+ "@typescript-eslint/no-extra-non-null-assertion": "error",
2185
+ "@typescript-eslint/no-misused-new": "error",
2186
+ "@typescript-eslint/no-namespace": "error",
2187
+ "@typescript-eslint/no-non-null-asserted-optional-chain": "error",
2188
+ "@typescript-eslint/no-require-imports": "error",
2189
+ "@typescript-eslint/no-this-alias": "error",
2190
+ "@typescript-eslint/no-unnecessary-type-constraint": "error",
2191
+ "@typescript-eslint/no-unsafe-declaration-merging": "error",
2192
+ "@typescript-eslint/prefer-as-const": "error",
2193
+ "@typescript-eslint/prefer-namespace-keyword": "error",
2194
+ "@typescript-eslint/triple-slash-reference": "error",
2195
+ "@typescript-eslint/explicit-function-return-type": 0,
2196
+ "@typescript-eslint/no-use-before-define": 0,
2197
+ "@typescript-eslint/no-empty-function": 0,
2198
+ "@typescript-eslint/no-unused-vars": [
2199
+ 2,
2200
+ {
2201
+ "varsIgnorePattern": "^_.*$",
2202
+ "argsIgnorePattern": "^_.*$"
2203
+ }
2204
+ ],
2205
+ "@typescript-eslint/no-explicit-any": "error",
2206
+ "@typescript-eslint/array-type": "off",
2207
+ "@typescript-eslint/ban-ts-comment": [
2208
+ "error",
2209
+ {
2210
+ "ts-expect-error": "allow-with-description"
2211
+ }
2212
+ ],
2213
+ "@typescript-eslint/no-wrapper-object-types": "error",
2214
+ "@typescript-eslint/no-unsafe-function-type": "error",
2215
+ "@typescript-eslint/no-restricted-types": [
2216
+ "error",
2217
+ {
2218
+ "types": {
2219
+ "String": {
2220
+ "message": "Use 'string' instead",
2221
+ "fixWith": "string"
2222
+ },
2223
+ "Number": {
2224
+ "message": "Use 'number' instead",
2225
+ "fixWith": "number"
2226
+ },
2227
+ "Boolean": {
2228
+ "message": "Use 'boolean' instead",
2229
+ "fixWith": "boolean"
2230
+ },
2231
+ "Symbol": {
2232
+ "message": "Use 'symbol' instead",
2233
+ "fixWith": "symbol"
2234
+ }
2235
+ }
2236
+ }
2237
+ ],
2238
+ "@typescript-eslint/explicit-member-accessibility": "off",
2239
+ "@typescript-eslint/interface-name-prefix": "off",
2240
+ "@typescript-eslint/member-ordering": "off",
2241
+ "@typescript-eslint/no-inferrable-types": "off",
2242
+ "@typescript-eslint/no-non-null-assertion": "off",
2243
+ "no-restricted-syntax": [
2244
+ "error",
2245
+ {
2246
+ "selector": "MemberExpression[object.name='React']",
2247
+ "message": "Do not use `React.*`. Use named imports instead."
2248
+ },
2249
+ {
2250
+ "selector": "TSTypeReference[typeName.type='TSQualifiedName'][typeName.left.name='React']",
2251
+ "message": "Do not use `React.*` types. Use named imports instead."
2252
+ },
2253
+ {
2254
+ "selector": "ExportNamespaceSpecifier",
2255
+ "message": "Usage of 'export * as …' is forbidden."
2256
+ },
2257
+ {
2258
+ "selector": "ExportAllDeclaration",
2259
+ "message": "Usage of `export * from` is forbidden."
2260
+ },
2261
+ {
2262
+ "selector": "ImportDeclaration[source.value=/^(?!.*reference_workspace)\\./] ImportNamespaceSpecifier",
2263
+ "message": "Do not use `import * as ...` from relative paths."
2264
+ }
2265
+ ],
1462
2266
  "@typescript-eslint/consistent-type-imports": [
1463
2267
  "error",
1464
2268
  {
1465
2269
  "prefer": "type-imports",
1466
2270
  "fixStyle": "inline-type-imports"
1467
2271
  }
2272
+ ],
2273
+ "@typescript-eslint/prefer-optional-chain": "error",
2274
+ "@typescript-eslint/consistent-type-exports": [
2275
+ "error",
2276
+ {
2277
+ "fixMixedExportsWithInlineTypeSpecifier": false
2278
+ }
2279
+ ],
2280
+ "@typescript-eslint/naming-convention": [
2281
+ "error",
2282
+ {
2283
+ "selector": "interface",
2284
+ "format": [
2285
+ "PascalCase"
2286
+ ],
2287
+ "custom": {
2288
+ "regex": "^I[A-Z]",
2289
+ "match": true
2290
+ }
2291
+ }
1468
2292
  ]
2293
+ },
2294
+ "parser": "@typescript-eslint/parser",
2295
+ "parserOptions": {
2296
+ "ecmaVersion": 2022,
2297
+ "sourceType": "module",
2298
+ "projectService": true
2299
+ }
2300
+ },
2301
+ {
2302
+ "files": [
2303
+ "**/eslint.config.ts"
2304
+ ],
2305
+ "rules": {
2306
+ "no-barrel-files/no-barrel-files": "off"
1469
2307
  }
1470
2308
  },
1471
2309
  {
1472
- "parser": "@typescript-eslint/parser",
1473
2310
  "files": [
1474
2311
  "**/*.ts",
2312
+ "**/*.cts",
2313
+ "**/*.mts",
1475
2314
  "**/*.tsx"
1476
2315
  ],
1477
- "extends": [
1478
- "plugin:import-x/typescript"
1479
- ]
2316
+ "settings": {
2317
+ "import-x/extensions": [
2318
+ ".ts",
2319
+ ".cts",
2320
+ ".mts",
2321
+ ".tsx",
2322
+ ".js",
2323
+ ".jsx",
2324
+ ".mjs",
2325
+ ".cjs"
2326
+ ],
2327
+ "import-x/external-module-folders": [
2328
+ "node_modules",
2329
+ "node_modules/@types"
2330
+ ],
2331
+ "import-x/parsers": {
2332
+ "@typescript-eslint/parser": [
2333
+ ".ts",
2334
+ ".cts",
2335
+ ".mts",
2336
+ ".tsx"
2337
+ ]
2338
+ },
2339
+ "import-x/resolver": {
2340
+ "typescript": {
2341
+ "alwaysTryTypes": true
2342
+ }
2343
+ }
2344
+ }
1480
2345
  },
1481
2346
  {
1482
2347
  "files": [
@@ -1506,21 +2371,12 @@
1506
2371
  }
1507
2372
  ],
1508
2373
  "settings": {
1509
- "import-x/resolver": {
1510
- "typescript": {
1511
- "alwaysTryTypes": true
1512
- },
1513
- "node": {
1514
- "extensions": [
1515
- ".ts",
1516
- ".tsx",
1517
- ".js",
1518
- ".jsx",
1519
- ".mjs",
1520
- ".cjs"
1521
- ]
1522
- }
1523
- },
2374
+ "import-x/extensions": [
2375
+ ".js",
2376
+ ".jsx",
2377
+ ".mjs",
2378
+ ".cjs"
2379
+ ],
1524
2380
  "react": {
1525
2381
  "version": "detect"
1526
2382
  }