@ntnyq/eslint-config 3.0.0-beta.1 → 3.0.0-beta.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -1,30 +1,52 @@
1
+ import { FlatConfigComposer } from 'eslint-flat-config-utils';
2
+ import { FlatGitignoreOptions } from 'eslint-config-flat-gitignore';
3
+ import { ESLintPluginCommandOptions } from 'eslint-plugin-command/types';
1
4
  import { Linter } from 'eslint';
2
5
  export { default as tseslint } from 'typescript-eslint';
6
+ import * as vueEslintParser from 'vue-eslint-parser';
7
+ export { vueEslintParser as parserVue };
8
+ import * as tomlEslintParser from 'toml-eslint-parser';
9
+ export { tomlEslintParser as parserToml };
10
+ import * as yamlEslintParser from 'yaml-eslint-parser';
11
+ export { yamlEslintParser as parserYaml };
12
+ import * as jsoncEslintParser from 'jsonc-eslint-parser';
13
+ export { jsoncEslintParser as parserJsonc };
3
14
  import * as eslintPluginRegexp from 'eslint-plugin-regexp';
4
15
  export { eslintPluginRegexp as pluginRegexp };
5
16
  export { default as pluginNode } from 'eslint-plugin-n';
6
17
  export { default as pluginVue } from 'eslint-plugin-vue';
7
18
  export { default as pluginYaml } from 'eslint-plugin-yml';
8
19
  export { default as pluginToml } from 'eslint-plugin-toml';
9
- export { default as pluginJsonc } from 'eslint-plugin-jsonc';
20
+ export { default as pluginMarkdown } from '@eslint/markdown';
21
+ export { default as pluginAntfu } from 'eslint-plugin-antfu';
10
22
  export { default as pluginJsdoc } from 'eslint-plugin-jsdoc';
23
+ export { default as pluginJsonc } from 'eslint-plugin-jsonc';
11
24
  export { default as pluginUnoCSS } from '@unocss/eslint-plugin';
12
25
  export { default as pluginVitest } from '@vitest/eslint-plugin';
13
- export { default as pluginUnicorn } from 'eslint-plugin-unicorn';
14
26
  export { default as pluginImport } from 'eslint-plugin-import-x';
27
+ export { default as pluginUnicorn } from 'eslint-plugin-unicorn';
15
28
  export { default as pluginPrettier } from 'eslint-plugin-prettier';
16
- export { default as pluginMarkdown } from 'eslint-plugin-markdown';
17
29
  export { default as pluginPerfectionist } from 'eslint-plugin-perfectionist';
18
30
  export { default as pluginUnusedImports } from 'eslint-plugin-unused-imports';
19
31
  export { default as pluginComments } from '@eslint-community/eslint-plugin-eslint-comments';
20
- import * as tomlEslintParser from 'toml-eslint-parser';
21
- export { tomlEslintParser as parserToml };
22
- import * as yamlEslintParser from 'yaml-eslint-parser';
23
- export { yamlEslintParser as parserYaml };
24
- import * as vueEslintParser from 'vue-eslint-parser';
25
- export { vueEslintParser as parserVue };
26
- import * as jsoncEslintParser from 'jsonc-eslint-parser';
27
- export { jsoncEslintParser as parserJsonc };
32
+
33
+ /**
34
+ * @file Type Utils
35
+ */
36
+ type Arrayable<T> = T | T[];
37
+ type Awaitable<T> = T | Promise<T>;
38
+ /**
39
+ * A literal type that supports custom further strings but preserves autocompletion in IDEs.
40
+ *
41
+ * @see https://github.com/microsoft/TypeScript/issues/29729#issuecomment-471566609
42
+ */
43
+ type LiteralUnion<Union extends Base, Base = string> = Union | (Base & {
44
+ zz_IGNORE_ME?: never;
45
+ });
46
+ type InteropModuleDefault<T> = T extends {
47
+ default: infer U;
48
+ } ? U : T;
49
+ type ResolvedOptions<T> = T extends boolean ? never : NonNullable<T>;
28
50
 
29
51
  interface RuleOptions {
30
52
  /**
@@ -217,6 +239,11 @@ interface RuleOptions {
217
239
  * @see https://typescript-eslint.io/rules/no-confusing-void-expression
218
240
  */
219
241
  '@typescript-eslint/no-confusing-void-expression'?: Linter.RuleEntry<TypescriptEslintNoConfusingVoidExpression>;
242
+ /**
243
+ * Disallow using code marked as `@deprecated`
244
+ * @see https://typescript-eslint.io/rules/no-deprecated
245
+ */
246
+ '@typescript-eslint/no-deprecated'?: Linter.RuleEntry<[]>;
220
247
  /**
221
248
  * Disallow duplicate class members
222
249
  * @see https://typescript-eslint.io/rules/no-dupe-class-members
@@ -704,10 +731,60 @@ interface RuleOptions {
704
731
  */
705
732
  '@typescript-eslint/unified-signatures'?: Linter.RuleEntry<TypescriptEslintUnifiedSignatures>;
706
733
  /**
707
- * Enforce typing arguments in `.catch()` callbacks as `unknown`
734
+ * Enforce typing arguments in Promise rejection callbacks as `unknown`
708
735
  * @see https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable
709
736
  */
710
737
  '@typescript-eslint/use-unknown-in-catch-callback-variable'?: Linter.RuleEntry<[]>;
738
+ /**
739
+ * Having line breaks styles to object, array and named imports
740
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-chaining.md
741
+ */
742
+ 'antfu/consistent-chaining'?: Linter.RuleEntry<AntfuConsistentChaining>;
743
+ /**
744
+ * Having line breaks styles to object, array and named imports
745
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/consistent-list-newline.md
746
+ */
747
+ 'antfu/consistent-list-newline'?: Linter.RuleEntry<AntfuConsistentListNewline>;
748
+ /**
749
+ * Enforce Anthony's style of curly bracket
750
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/curly.md
751
+ */
752
+ 'antfu/curly'?: Linter.RuleEntry<[]>;
753
+ /**
754
+ * Newline after if
755
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/if-newline.md
756
+ */
757
+ 'antfu/if-newline'?: Linter.RuleEntry<[]>;
758
+ /**
759
+ * Fix duplication in imports
760
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/import-dedupe.md
761
+ */
762
+ 'antfu/import-dedupe'?: Linter.RuleEntry<[]>;
763
+ /**
764
+ * Enforce consistent indentation in `unindent` template tag
765
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/indent-unindent.md
766
+ */
767
+ 'antfu/indent-unindent'?: Linter.RuleEntry<AntfuIndentUnindent>;
768
+ /**
769
+ * Prevent importing modules in `dist` folder
770
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-dist.test.ts
771
+ */
772
+ 'antfu/no-import-dist'?: Linter.RuleEntry<[]>;
773
+ /**
774
+ * Prevent importing modules in `node_modules` folder by relative or absolute path
775
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-import-node-modules-by-path.test.ts
776
+ */
777
+ 'antfu/no-import-node-modules-by-path'?: Linter.RuleEntry<[]>;
778
+ /**
779
+ * Do not use `exports =`
780
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/no-ts-export-equal.test.ts
781
+ */
782
+ 'antfu/no-ts-export-equal'?: Linter.RuleEntry<[]>;
783
+ /**
784
+ * Enforce top-level functions to be declared with function keyword
785
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/top-level-function.md
786
+ */
787
+ 'antfu/top-level-function'?: Linter.RuleEntry<[]>;
711
788
  /**
712
789
  * Comment-as-command for one-off codemod with ESLint
713
790
  * @see https://github.com/antfu/eslint-plugin-command
@@ -715,228 +792,233 @@ interface RuleOptions {
715
792
  'command/command'?: Linter.RuleEntry<[]>;
716
793
  /**
717
794
  * Enforce or ban the use of inline type-only markers for named imports.
718
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/consistent-type-specifier-style.md
795
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/consistent-type-specifier-style.md
719
796
  */
720
797
  'import/consistent-type-specifier-style'?: Linter.RuleEntry<ImportConsistentTypeSpecifierStyle>;
721
798
  /**
722
799
  * Ensure a default export is present, given a default import.
723
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/default.md
800
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/default.md
724
801
  */
725
802
  'import/default'?: Linter.RuleEntry<[]>;
726
803
  /**
727
804
  * Enforce a leading comment with the webpackChunkName for dynamic imports.
728
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/dynamic-import-chunkname.md
805
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/dynamic-import-chunkname.md
729
806
  */
730
807
  'import/dynamic-import-chunkname'?: Linter.RuleEntry<ImportDynamicImportChunkname>;
731
808
  /**
732
809
  * Forbid any invalid exports, i.e. re-export of the same name.
733
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/export.md
810
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/export.md
734
811
  */
735
812
  'import/export'?: Linter.RuleEntry<[]>;
736
813
  /**
737
814
  * Ensure all exports appear after other statements.
738
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/exports-last.md
815
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/exports-last.md
739
816
  */
740
817
  'import/exports-last'?: Linter.RuleEntry<[]>;
741
818
  /**
742
819
  * Ensure consistent use of file extension within the import path.
743
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/extensions.md
820
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/extensions.md
744
821
  */
745
822
  'import/extensions'?: Linter.RuleEntry<ImportExtensions>;
746
823
  /**
747
824
  * Ensure all imports appear before other statements.
748
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/first.md
825
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/first.md
749
826
  */
750
827
  'import/first'?: Linter.RuleEntry<ImportFirst>;
751
828
  /**
752
829
  * Prefer named exports to be grouped together in a single export declaration.
753
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/group-exports.md
830
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/group-exports.md
754
831
  */
755
832
  'import/group-exports'?: Linter.RuleEntry<[]>;
756
833
  /**
757
834
  * Replaced by `import-x/first`.
758
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/7b25c1cb95ee18acc1531002fd343e1e6031f9ed/docs/rules/imports-first.md
835
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/imports-first.md
759
836
  * @deprecated
760
837
  */
761
838
  'import/imports-first'?: Linter.RuleEntry<ImportImportsFirst>;
762
839
  /**
763
840
  * Enforce the maximum number of dependencies a module can have.
764
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/max-dependencies.md
841
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/max-dependencies.md
765
842
  */
766
843
  'import/max-dependencies'?: Linter.RuleEntry<ImportMaxDependencies>;
767
844
  /**
768
845
  * Ensure named imports correspond to a named export in the remote file.
769
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/named.md
846
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/named.md
770
847
  */
771
848
  'import/named'?: Linter.RuleEntry<ImportNamed>;
772
849
  /**
773
850
  * Ensure imported namespaces contain dereferenced properties as they are dereferenced.
774
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/namespace.md
851
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/namespace.md
775
852
  */
776
853
  'import/namespace'?: Linter.RuleEntry<ImportNamespace>;
777
854
  /**
778
855
  * Enforce a newline after import statements.
779
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/newline-after-import.md
856
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/newline-after-import.md
780
857
  */
781
858
  'import/newline-after-import'?: Linter.RuleEntry<ImportNewlineAfterImport>;
782
859
  /**
783
860
  * Forbid import of modules using absolute paths.
784
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-absolute-path.md
861
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-absolute-path.md
785
862
  */
786
863
  'import/no-absolute-path'?: Linter.RuleEntry<ImportNoAbsolutePath>;
787
864
  /**
788
865
  * Forbid AMD `require` and `define` calls.
789
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-amd.md
866
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-amd.md
790
867
  */
791
868
  'import/no-amd'?: Linter.RuleEntry<[]>;
792
869
  /**
793
870
  * Forbid anonymous values as default exports.
794
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-anonymous-default-export.md
871
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-anonymous-default-export.md
795
872
  */
796
873
  'import/no-anonymous-default-export'?: Linter.RuleEntry<ImportNoAnonymousDefaultExport>;
797
874
  /**
798
875
  * Forbid CommonJS `require` calls and `module.exports` or `exports.*`.
799
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-commonjs.md
876
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-commonjs.md
800
877
  */
801
878
  'import/no-commonjs'?: Linter.RuleEntry<ImportNoCommonjs>;
802
879
  /**
803
880
  * Forbid a module from importing a module with a dependency path back to itself.
804
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-cycle.md
881
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-cycle.md
805
882
  */
806
883
  'import/no-cycle'?: Linter.RuleEntry<ImportNoCycle>;
807
884
  /**
808
885
  * Forbid default exports.
809
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-default-export.md
886
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-default-export.md
810
887
  */
811
888
  'import/no-default-export'?: Linter.RuleEntry<[]>;
812
889
  /**
813
890
  * Forbid imported names marked with `@deprecated` documentation tag.
814
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-deprecated.md
891
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-deprecated.md
815
892
  */
816
893
  'import/no-deprecated'?: Linter.RuleEntry<[]>;
817
894
  /**
818
895
  * Forbid repeated import of the same module in multiple places.
819
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-duplicates.md
896
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-duplicates.md
820
897
  */
821
898
  'import/no-duplicates'?: Linter.RuleEntry<ImportNoDuplicates>;
822
899
  /**
823
900
  * Forbid `require()` calls with expressions.
824
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-dynamic-require.md
901
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-dynamic-require.md
825
902
  */
826
903
  'import/no-dynamic-require'?: Linter.RuleEntry<ImportNoDynamicRequire>;
827
904
  /**
828
905
  * Forbid empty named import blocks.
829
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-empty-named-blocks.md
906
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-empty-named-blocks.md
830
907
  */
831
908
  'import/no-empty-named-blocks'?: Linter.RuleEntry<[]>;
832
909
  /**
833
910
  * Forbid the use of extraneous packages.
834
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-extraneous-dependencies.md
911
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-extraneous-dependencies.md
835
912
  */
836
913
  'import/no-extraneous-dependencies'?: Linter.RuleEntry<ImportNoExtraneousDependencies>;
837
914
  /**
838
915
  * Forbid import statements with CommonJS module.exports.
839
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-import-module-exports.md
916
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-import-module-exports.md
840
917
  */
841
918
  'import/no-import-module-exports'?: Linter.RuleEntry<ImportNoImportModuleExports>;
842
919
  /**
843
920
  * Forbid importing the submodules of other modules.
844
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-internal-modules.md
921
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-internal-modules.md
845
922
  */
846
923
  'import/no-internal-modules'?: Linter.RuleEntry<ImportNoInternalModules>;
847
924
  /**
848
925
  * Forbid the use of mutable exports with `var` or `let`.
849
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-mutable-exports.md
926
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-mutable-exports.md
850
927
  */
851
928
  'import/no-mutable-exports'?: Linter.RuleEntry<[]>;
852
929
  /**
853
930
  * Forbid use of exported name as identifier of default export.
854
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default.md
931
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-named-as-default.md
855
932
  */
856
933
  'import/no-named-as-default'?: Linter.RuleEntry<[]>;
857
934
  /**
858
935
  * Forbid use of exported name as property of default export.
859
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-as-default-member.md
936
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-named-as-default-member.md
860
937
  */
861
938
  'import/no-named-as-default-member'?: Linter.RuleEntry<[]>;
862
939
  /**
863
940
  * Forbid named default exports.
864
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-default.md
941
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-named-default.md
865
942
  */
866
943
  'import/no-named-default'?: Linter.RuleEntry<[]>;
867
944
  /**
868
945
  * Forbid named exports.
869
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-named-export.md
946
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-named-export.md
870
947
  */
871
948
  'import/no-named-export'?: Linter.RuleEntry<[]>;
872
949
  /**
873
950
  * Forbid namespace (a.k.a. "wildcard" `*`) imports.
874
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-namespace.md
951
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-namespace.md
875
952
  */
876
953
  'import/no-namespace'?: Linter.RuleEntry<ImportNoNamespace>;
877
954
  /**
878
955
  * Forbid Node.js builtin modules.
879
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-nodejs-modules.md
956
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-nodejs-modules.md
880
957
  */
881
958
  'import/no-nodejs-modules'?: Linter.RuleEntry<ImportNoNodejsModules>;
882
959
  /**
883
960
  * Forbid importing packages through relative paths.
884
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-packages.md
961
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-relative-packages.md
885
962
  */
886
963
  'import/no-relative-packages'?: Linter.RuleEntry<ImportNoRelativePackages>;
887
964
  /**
888
965
  * Forbid importing modules from parent directories.
889
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-relative-parent-imports.md
966
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-relative-parent-imports.md
890
967
  */
891
968
  'import/no-relative-parent-imports'?: Linter.RuleEntry<ImportNoRelativeParentImports>;
969
+ /**
970
+ * Forbid importing a default export by a different name.
971
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-rename-default.md
972
+ */
973
+ 'import/no-rename-default'?: Linter.RuleEntry<ImportNoRenameDefault>;
892
974
  /**
893
975
  * Enforce which files can be imported in a given folder.
894
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-restricted-paths.md
976
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-restricted-paths.md
895
977
  */
896
978
  'import/no-restricted-paths'?: Linter.RuleEntry<ImportNoRestrictedPaths>;
897
979
  /**
898
980
  * Forbid a module from importing itself.
899
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-self-import.md
981
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-self-import.md
900
982
  */
901
983
  'import/no-self-import'?: Linter.RuleEntry<[]>;
902
984
  /**
903
985
  * Forbid unassigned imports.
904
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unassigned-import.md
986
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-unassigned-import.md
905
987
  */
906
988
  'import/no-unassigned-import'?: Linter.RuleEntry<ImportNoUnassignedImport>;
907
989
  /**
908
990
  * Ensure imports point to a file/module that can be resolved.
909
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unresolved.md
991
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-unresolved.md
910
992
  */
911
993
  'import/no-unresolved'?: Linter.RuleEntry<ImportNoUnresolved>;
912
994
  /**
913
995
  * Forbid modules without exports, or exports without matching import in another module.
914
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-unused-modules.md
996
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-unused-modules.md
915
997
  */
916
998
  'import/no-unused-modules'?: Linter.RuleEntry<ImportNoUnusedModules>;
917
999
  /**
918
1000
  * Forbid unnecessary path segments in import and require statements.
919
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-useless-path-segments.md
1001
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-useless-path-segments.md
920
1002
  */
921
1003
  'import/no-useless-path-segments'?: Linter.RuleEntry<ImportNoUselessPathSegments>;
922
1004
  /**
923
1005
  * Forbid webpack loader syntax in imports.
924
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/no-webpack-loader-syntax.md
1006
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/no-webpack-loader-syntax.md
925
1007
  */
926
1008
  'import/no-webpack-loader-syntax'?: Linter.RuleEntry<[]>;
927
1009
  /**
928
1010
  * Enforce a convention in module import order.
929
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/order.md
1011
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/order.md
930
1012
  */
931
1013
  'import/order'?: Linter.RuleEntry<ImportOrder>;
932
1014
  /**
933
1015
  * Prefer a default export if module exports a single name or multiple names.
934
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/prefer-default-export.md
1016
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/prefer-default-export.md
935
1017
  */
936
1018
  'import/prefer-default-export'?: Linter.RuleEntry<ImportPreferDefaultExport>;
937
1019
  /**
938
1020
  * Forbid potentially ambiguous parse goal (`script` vs. `module`).
939
- * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v3.1.0/docs/rules/unambiguous.md
1021
+ * @see https://github.com/un-ts/eslint-plugin-import-x/blob/v4.2.1/docs/rules/unambiguous.md
940
1022
  */
941
1023
  'import/unambiguous'?: Linter.RuleEntry<[]>;
942
1024
  /**
@@ -1442,6 +1524,34 @@ interface RuleOptions {
1442
1524
  * @see https://ota-meshi.github.io/eslint-plugin-jsonc/rules/vue-custom-block/no-parsing-error.html
1443
1525
  */
1444
1526
  'jsonc/vue-custom-block/no-parsing-error'?: Linter.RuleEntry<[]>;
1527
+ /**
1528
+ * Require languages for fenced code blocks.
1529
+ */
1530
+ 'markdown/fenced-code-language'?: Linter.RuleEntry<MarkdownFencedCodeLanguage>;
1531
+ /**
1532
+ * Enforce heading levels increment by one.
1533
+ */
1534
+ 'markdown/heading-increment'?: Linter.RuleEntry<[]>;
1535
+ /**
1536
+ * Disallow duplicate headings in the same document.
1537
+ */
1538
+ 'markdown/no-duplicate-headings'?: Linter.RuleEntry<[]>;
1539
+ /**
1540
+ * Disallow empty links.
1541
+ */
1542
+ 'markdown/no-empty-links'?: Linter.RuleEntry<[]>;
1543
+ /**
1544
+ * Disallow HTML tags.
1545
+ */
1546
+ 'markdown/no-html'?: Linter.RuleEntry<MarkdownNoHtml>;
1547
+ /**
1548
+ * Disallow invalid label references.
1549
+ */
1550
+ 'markdown/no-invalid-label-refs'?: Linter.RuleEntry<[]>;
1551
+ /**
1552
+ * Disallow missing label references.
1553
+ */
1554
+ 'markdown/no-missing-label-refs'?: Linter.RuleEntry<[]>;
1445
1555
  /**
1446
1556
  * require `return` statements after callbacks
1447
1557
  * @see https://github.com/eslint-community/eslint-plugin-n/blob/HEAD/docs/rules/callback-return.md
@@ -1714,6 +1824,11 @@ interface RuleOptions {
1714
1824
  * @see https://perfectionist.dev/rules/sort-objects
1715
1825
  */
1716
1826
  'perfectionist/sort-objects'?: Linter.RuleEntry<PerfectionistSortObjects>;
1827
+ /**
1828
+ * Enforce sorted sets.
1829
+ * @see https://perfectionist.dev/rules/sort-sets
1830
+ */
1831
+ 'perfectionist/sort-sets'?: Linter.RuleEntry<PerfectionistSortSets>;
1717
1832
  /**
1718
1833
  * Enforce sorted Svelte attributes.
1719
1834
  * @see https://perfectionist.dev/rules/sort-svelte-attributes
@@ -2969,6 +3084,16 @@ interface RuleOptions {
2969
3084
  * @see https://unocss.dev/integrations/eslint#rules
2970
3085
  */
2971
3086
  'unocss/order-attributify'?: Linter.RuleEntry<[]>;
3087
+ /**
3088
+ * Disallow unused variables
3089
+ * @see https://github.com/sweepline/eslint-plugin-unused-imports/blob/master/docs/rules/no-unused-imports.md
3090
+ */
3091
+ 'unused-imports/no-unused-imports'?: Linter.RuleEntry<UnusedImportsNoUnusedImports>;
3092
+ /**
3093
+ * Disallow unused variables
3094
+ * @see https://github.com/sweepline/eslint-plugin-unused-imports/blob/master/docs/rules/no-unused-vars.md
3095
+ */
3096
+ 'unused-imports/no-unused-vars'?: Linter.RuleEntry<UnusedImportsNoUnusedVars>;
2972
3097
  /**
2973
3098
  * Enforce linebreaks after opening and before closing array brackets in `<template>`
2974
3099
  * @see https://eslint.vuejs.org/rules/array-bracket-newline.html
@@ -3086,7 +3211,7 @@ interface RuleOptions {
3086
3211
  */
3087
3212
  'vue/define-emits-declaration'?: Linter.RuleEntry<VueDefineEmitsDeclaration>;
3088
3213
  /**
3089
- * enforce order of `defineEmits` and `defineProps` compiler macros
3214
+ * enforce order of compiler macros (`defineProps`, `defineEmits`, etc.)
3090
3215
  * @see https://eslint.vuejs.org/rules/define-macros-order.html
3091
3216
  */
3092
3217
  'vue/define-macros-order'?: Linter.RuleEntry<VueDefineMacrosOrder>;
@@ -3215,6 +3340,16 @@ interface RuleOptions {
3215
3340
  * @see https://eslint.vuejs.org/rules/max-lines-per-block.html
3216
3341
  */
3217
3342
  'vue/max-lines-per-block'?: Linter.RuleEntry<VueMaxLinesPerBlock>;
3343
+ /**
3344
+ * enforce maximum number of props in Vue component
3345
+ * @see https://eslint.vuejs.org/rules/max-props.html
3346
+ */
3347
+ 'vue/max-props'?: Linter.RuleEntry<VueMaxProps>;
3348
+ /**
3349
+ * enforce maximum depth of template
3350
+ * @see https://eslint.vuejs.org/rules/max-template-depth.html
3351
+ */
3352
+ 'vue/max-template-depth'?: Linter.RuleEntry<VueMaxTemplateDepth>;
3218
3353
  /**
3219
3354
  * require component names to be always multi-word
3220
3355
  * @see https://eslint.vuejs.org/rules/multi-word-component-names.html
@@ -3271,7 +3406,7 @@ interface RuleOptions {
3271
3406
  */
3272
3407
  'vue/no-child-content'?: Linter.RuleEntry<VueNoChildContent>;
3273
3408
  /**
3274
- * disallow accessing computed properties in `data`.
3409
+ * disallow accessing computed properties in `data`
3275
3410
  * @see https://eslint.vuejs.org/rules/no-computed-properties-in-data.html
3276
3411
  */
3277
3412
  'vue/no-computed-properties-in-data'?: Linter.RuleEntry<[]>;
@@ -3819,7 +3954,7 @@ interface RuleOptions {
3819
3954
  */
3820
3955
  'vue/padding-lines-in-component-definition'?: Linter.RuleEntry<VuePaddingLinesInComponentDefinition>;
3821
3956
  /**
3822
- * enforce use of `defineOptions` instead of default export.
3957
+ * enforce use of `defineOptions` instead of default export
3823
3958
  * @see https://eslint.vuejs.org/rules/prefer-define-options.html
3824
3959
  */
3825
3960
  'vue/prefer-define-options'?: Linter.RuleEntry<[]>;
@@ -3863,6 +3998,11 @@ interface RuleOptions {
3863
3998
  * @see https://eslint.vuejs.org/rules/require-component-is.html
3864
3999
  */
3865
4000
  'vue/require-component-is'?: Linter.RuleEntry<[]>;
4001
+ /**
4002
+ * require components to be the default export
4003
+ * @see https://eslint.vuejs.org/rules/require-default-export.html
4004
+ */
4005
+ 'vue/require-default-export'?: Linter.RuleEntry<[]>;
3866
4006
  /**
3867
4007
  * require default value for props
3868
4008
  * @see https://eslint.vuejs.org/rules/require-default-prop.html
@@ -3932,7 +4072,7 @@ interface RuleOptions {
3932
4072
  * require control the display of the content inside `<transition>`
3933
4073
  * @see https://eslint.vuejs.org/rules/require-toggle-inside-transition.html
3934
4074
  */
3935
- 'vue/require-toggle-inside-transition'?: Linter.RuleEntry<[]>;
4075
+ 'vue/require-toggle-inside-transition'?: Linter.RuleEntry<VueRequireToggleInsideTransition>;
3936
4076
  /**
3937
4077
  * enforce adding type declarations to object props
3938
4078
  * @see https://eslint.vuejs.org/rules/require-typed-object-prop.html
@@ -4448,8 +4588,8 @@ type TypescriptEslintInitDeclarations = ([] | ["always"] | [] | ["never"] | [
4448
4588
  ]);
4449
4589
  type TypescriptEslintMaxParams = [] | [
4450
4590
  {
4451
- maximum?: number;
4452
4591
  max?: number;
4592
+ maximum?: number;
4453
4593
  countVoidThis?: boolean;
4454
4594
  }
4455
4595
  ];
@@ -5045,12 +5185,12 @@ type TypescriptEslintNoUnusedVars = [] | [
5045
5185
  vars?: ("all" | "local");
5046
5186
  varsIgnorePattern?: string;
5047
5187
  args?: ("all" | "after-used" | "none");
5048
- ignoreRestSiblings?: boolean;
5049
5188
  argsIgnorePattern?: string;
5050
5189
  caughtErrors?: ("all" | "none");
5051
5190
  caughtErrorsIgnorePattern?: string;
5052
5191
  destructuredArrayIgnorePattern?: string;
5053
5192
  ignoreClassWithStaticInitBlock?: boolean;
5193
+ ignoreRestSiblings?: boolean;
5054
5194
  reportUsedIgnorePattern?: boolean;
5055
5195
  })
5056
5196
  ];
@@ -5218,7 +5358,7 @@ type TypescriptEslintRestrictTemplateExpressions = [] | [
5218
5358
  allowNever?: boolean;
5219
5359
  }
5220
5360
  ];
5221
- type TypescriptEslintReturnAwait = [] | [("in-try-catch" | "always" | "never" | "error-handling-correctness-only")];
5361
+ type TypescriptEslintReturnAwait = [] | [(("always" | "error-handling-correctness-only" | "in-try-catch" | "never") & string)];
5222
5362
  type TypescriptEslintSortTypeConstituents = [] | [
5223
5363
  {
5224
5364
  checkIntersections?: boolean;
@@ -5275,6 +5415,41 @@ type TypescriptEslintUnifiedSignatures = [] | [
5275
5415
  ignoreDifferentlyNamedParameters?: boolean;
5276
5416
  }
5277
5417
  ];
5418
+ type AntfuConsistentChaining = [] | [
5419
+ {
5420
+ allowLeadingPropertyAccess?: boolean;
5421
+ }
5422
+ ];
5423
+ type AntfuConsistentListNewline = [] | [
5424
+ {
5425
+ ArrayExpression?: boolean;
5426
+ ArrayPattern?: boolean;
5427
+ ArrowFunctionExpression?: boolean;
5428
+ CallExpression?: boolean;
5429
+ ExportNamedDeclaration?: boolean;
5430
+ FunctionDeclaration?: boolean;
5431
+ FunctionExpression?: boolean;
5432
+ ImportDeclaration?: boolean;
5433
+ JSONArrayExpression?: boolean;
5434
+ JSONObjectExpression?: boolean;
5435
+ JSXOpeningElement?: boolean;
5436
+ NewExpression?: boolean;
5437
+ ObjectExpression?: boolean;
5438
+ ObjectPattern?: boolean;
5439
+ TSFunctionType?: boolean;
5440
+ TSInterfaceDeclaration?: boolean;
5441
+ TSTupleType?: boolean;
5442
+ TSTypeLiteral?: boolean;
5443
+ TSTypeParameterDeclaration?: boolean;
5444
+ TSTypeParameterInstantiation?: boolean;
5445
+ }
5446
+ ];
5447
+ type AntfuIndentUnindent = [] | [
5448
+ {
5449
+ indent?: number;
5450
+ tags?: string[];
5451
+ }
5452
+ ];
5278
5453
  type ImportConsistentTypeSpecifierStyle = [] | [("prefer-inline" | "prefer-top-level")];
5279
5454
  type ImportDynamicImportChunkname = [] | [
5280
5455
  {
@@ -5394,6 +5569,7 @@ type ImportNoExtraneousDependencies = [] | [
5394
5569
  packageDir?: (string | unknown[]);
5395
5570
  includeInternal?: boolean;
5396
5571
  includeTypes?: boolean;
5572
+ whitelist?: unknown[];
5397
5573
  }
5398
5574
  ];
5399
5575
  type ImportNoImportModuleExports = [] | [
@@ -5435,6 +5611,12 @@ type ImportNoRelativeParentImports = [] | [
5435
5611
  ignore?: [string, ...(string)[]];
5436
5612
  }
5437
5613
  ];
5614
+ type ImportNoRenameDefault = [] | [
5615
+ {
5616
+ commonjs?: boolean;
5617
+ preventRenamingBindings?: boolean;
5618
+ }
5619
+ ];
5438
5620
  type ImportNoRestrictedPaths = [] | [
5439
5621
  {
5440
5622
  zones?: [
@@ -6313,6 +6495,16 @@ type JsoncSpaceUnaryOps = [] | [
6313
6495
  };
6314
6496
  }
6315
6497
  ];
6498
+ type MarkdownFencedCodeLanguage = [] | [
6499
+ {
6500
+ required?: string[];
6501
+ }
6502
+ ];
6503
+ type MarkdownNoHtml = [] | [
6504
+ {
6505
+ allowed?: string[];
6506
+ }
6507
+ ];
6316
6508
  type NodeCallbackReturn = [] | [string[]];
6317
6509
  type NodeExportsStyle = [] | [("module.exports" | "exports")] | [
6318
6510
  ("module.exports" | "exports"),
@@ -6590,9 +6782,27 @@ type PerfectionistSortClasses = [] | [
6590
6782
  ignoreCase?: boolean;
6591
6783
  partitionByComment?: (string[] | boolean | string);
6592
6784
  groups?: (string | string[])[];
6593
- customGroups?: {
6785
+ customGroups?: ({
6594
6786
  [k: string]: (string | string[]) | undefined;
6595
- };
6787
+ } | ({
6788
+ groupName?: string;
6789
+ type?: ("alphabetical" | "line-length" | "natural" | "unsorted");
6790
+ order?: ("desc" | "asc");
6791
+ anyOf?: {
6792
+ selector?: ("accessor-property" | "index-signature" | "constructor" | "static-block" | "get-method" | "set-method" | "function-property" | "property" | "method");
6793
+ modifiers?: ("protected" | "private" | "public" | "static" | "abstract" | "override" | "readonly" | "decorated" | "declare" | "optional")[];
6794
+ elementNamePattern?: string;
6795
+ decoratorNamePattern?: string;
6796
+ }[];
6797
+ } | {
6798
+ groupName?: string;
6799
+ type?: ("alphabetical" | "line-length" | "natural" | "unsorted");
6800
+ order?: ("desc" | "asc");
6801
+ selector?: ("accessor-property" | "index-signature" | "constructor" | "static-block" | "get-method" | "set-method" | "function-property" | "property" | "method");
6802
+ modifiers?: ("protected" | "private" | "public" | "static" | "abstract" | "override" | "readonly" | "decorated" | "declare" | "optional")[];
6803
+ elementNamePattern?: string;
6804
+ decoratorNamePattern?: string;
6805
+ })[]);
6596
6806
  }
6597
6807
  ];
6598
6808
  type PerfectionistSortEnums = [] | [
@@ -6618,6 +6828,7 @@ type _PerfectionistSortImportsSortImports = (_PerfectionistSortImportsMaxLineLen
6618
6828
  order?: ("asc" | "desc");
6619
6829
  ignoreCase?: boolean;
6620
6830
  internalPattern?: string[];
6831
+ sortSideEffects?: boolean;
6621
6832
  newlinesBetween?: ("ignore" | "always" | "never");
6622
6833
  maxLineLength?: number;
6623
6834
  groups?: (string | string[])[];
@@ -6725,6 +6936,14 @@ type PerfectionistSortObjects = [] | [
6725
6936
  };
6726
6937
  }
6727
6938
  ];
6939
+ type PerfectionistSortSets = [] | [
6940
+ {
6941
+ type?: ("alphabetical" | "natural" | "line-length");
6942
+ order?: ("asc" | "desc");
6943
+ ignoreCase?: boolean;
6944
+ groupKind?: ("mixed" | "literals-first" | "spreads-first");
6945
+ }
6946
+ ];
6728
6947
  type PerfectionistSortSvelteAttributes = [] | [
6729
6948
  {
6730
6949
  type?: ("alphabetical" | "natural" | "line-length");
@@ -7292,6 +7511,34 @@ type UnocssEnforceClassCompile = [] | [
7292
7511
  enableFix?: boolean;
7293
7512
  }
7294
7513
  ];
7514
+ type UnusedImportsNoUnusedImports = [] | [
7515
+ (("all" | "local") | {
7516
+ vars?: ("all" | "local");
7517
+ varsIgnorePattern?: string;
7518
+ args?: ("all" | "after-used" | "none");
7519
+ argsIgnorePattern?: string;
7520
+ caughtErrors?: ("all" | "none");
7521
+ caughtErrorsIgnorePattern?: string;
7522
+ destructuredArrayIgnorePattern?: string;
7523
+ ignoreClassWithStaticInitBlock?: boolean;
7524
+ ignoreRestSiblings?: boolean;
7525
+ reportUsedIgnorePattern?: boolean;
7526
+ })
7527
+ ];
7528
+ type UnusedImportsNoUnusedVars = [] | [
7529
+ (("all" | "local") | {
7530
+ vars?: ("all" | "local");
7531
+ varsIgnorePattern?: string;
7532
+ args?: ("all" | "after-used" | "none");
7533
+ argsIgnorePattern?: string;
7534
+ caughtErrors?: ("all" | "none");
7535
+ caughtErrorsIgnorePattern?: string;
7536
+ destructuredArrayIgnorePattern?: string;
7537
+ ignoreClassWithStaticInitBlock?: boolean;
7538
+ ignoreRestSiblings?: boolean;
7539
+ reportUsedIgnorePattern?: boolean;
7540
+ })
7541
+ ];
7295
7542
  type VueArrayBracketNewline = [] | [
7296
7543
  (("always" | "never" | "consistent") | {
7297
7544
  multiline?: boolean;
@@ -7440,7 +7687,7 @@ type VueCustomEventNameCasing = ([] | [("kebab-case" | "camelCase")] | [
7440
7687
  type VueDefineEmitsDeclaration = [] | [("type-based" | "type-literal" | "runtime")];
7441
7688
  type VueDefineMacrosOrder = [] | [
7442
7689
  {
7443
- order?: ("defineEmits" | "defineProps" | "defineOptions" | "defineSlots" | "defineModel")[];
7690
+ order?: string[];
7444
7691
  defineExposeLast?: boolean;
7445
7692
  }
7446
7693
  ];
@@ -8002,6 +8249,16 @@ type VueMaxLinesPerBlock = [] | [
8002
8249
  skipBlankLines?: boolean;
8003
8250
  }
8004
8251
  ];
8252
+ type VueMaxProps = [] | [
8253
+ {
8254
+ maxProps?: number;
8255
+ }
8256
+ ];
8257
+ type VueMaxTemplateDepth = [] | [
8258
+ {
8259
+ maxDepth?: number;
8260
+ }
8261
+ ];
8005
8262
  type VueMultiWordComponentNames = [] | [
8006
8263
  {
8007
8264
  ignores?: string[];
@@ -8436,6 +8693,11 @@ type VueRequirePropComment = [] | [
8436
8693
  type?: ("JSDoc" | "line" | "block" | "any");
8437
8694
  }
8438
8695
  ];
8696
+ type VueRequireToggleInsideTransition = [] | [
8697
+ {
8698
+ additionalDirectives?: string[];
8699
+ }
8700
+ ];
8439
8701
  type VueReturnInComputedProperty = [] | [
8440
8702
  {
8441
8703
  treatUndefinedAsUnspecified?: boolean;
@@ -8773,53 +9035,21 @@ type YmlSpacedComment = [] | [("always" | "never")] | [
8773
9035
  markers?: string[];
8774
9036
  }
8775
9037
  ];
8776
- type ConfigName = 'ntnyq/command' | 'ntnyq/eslint-comments' | 'ntnyq/ignores' | 'ntnyq/imports' | 'ntnyq/js/recommended' | 'ntnyq/js/core' | 'ntnyq/js/script' | 'ntnyq/js/test' | 'ntnyq/jsdoc' | 'ntnyq/jsonc' | 'ntnyq/jsx' | 'markdown/recommended/plugin' | 'markdown/recommended/processor' | 'markdown/recommended/code-blocks' | 'ntnyq/markdown/extensions' | 'ntnyq/node' | 'ntnyq/prettier' | 'ntnyq/prettier/disabled' | 'ntnyq/regexp' | 'ntnyq/perfectionist' | 'ntnyq/sort/package-json' | 'ntnyq/sort/tsconfig' | 'typescript-eslint/base' | 'typescript-eslint/eslint-recommended' | 'typescript-eslint/recommended' | 'ntnyq/ts/core' | 'ntnyq/ts/dts' | 'ntnyq/ts/test' | 'ntnyq/ts/cjs' | 'ntnyq/unicorn' | 'ntnyq/unocss' | 'typescript-eslint/base' | 'typescript-eslint/eslint-recommended' | 'typescript-eslint/recommended' | 'ntnyq/ts/core' | 'ntnyq/vue/ts' | 'ntnyq/vue/core' | 'ntnyq/yaml' | 'ntnyq/toml';
9038
+ type ConfigNames = 'ntnyq/antfu' | 'ntnyq/command' | 'ntnyq/eslint-comments' | 'ntnyq/ignores' | 'ntnyq/imports' | 'ntnyq/gitignore' | 'ntnyq/js/recommended' | 'ntnyq/js/core' | 'ntnyq/js/scripts' | 'ntnyq/js/test' | 'ntnyq/jsdoc' | 'ntnyq/jsonc' | 'ntnyq/jsx' | 'ntnyq/markdown/recommended/plugin' | 'ntnyq/markdown/recommended/processor' | 'ntnyq/markdown/recommended/code-blocks' | 'ntnyq/markdown/disabled/code-blocks' | 'ntnyq/node' | 'ntnyq/prettier' | 'ntnyq/prettier/disabled' | 'ntnyq/regexp' | 'ntnyq/perfectionist' | 'ntnyq/sort/package-json' | 'ntnyq/sort/tsconfig' | 'typescript-eslint/base' | 'typescript-eslint/eslint-recommended' | 'typescript-eslint/recommended' | 'ntnyq/ts/core' | 'ntnyq/ts/dts' | 'ntnyq/ts/test' | 'ntnyq/ts/cjs' | 'ntnyq/unused-imports' | 'ntnyq/unicorn' | 'ntnyq/unocss' | 'typescript-eslint/base' | 'typescript-eslint/eslint-recommended' | 'typescript-eslint/recommended' | 'ntnyq/ts/core' | 'ntnyq/vue/ts' | 'ntnyq/vue/core' | 'ntnyq/yaml' | 'ntnyq/toml';
8777
9039
 
8778
- /**
8779
- * Parser options
8780
- */
8781
- type ParserOptions = Linter.ParserOptions;
8782
- /**
8783
- * Rules
8784
- */
8785
- type Rules = RuleOptions;
8786
9040
  /**
8787
9041
  * Typed flat config item
8788
9042
  */
8789
- type TypedConfigItem = Omit<Linter.Config<Linter.RulesRecord & Rules>, 'plugins'> & {
9043
+ type TypedConfigItem = Omit<Linter.Config<Linter.RulesRecord & RuleOptions>, 'plugins'> & {
8790
9044
  /**
8791
9045
  * Most plugin are not properly typed
8792
9046
  */
8793
9047
  plugins?: Record<string, any>;
8794
9048
  };
8795
9049
  /**
8796
- * Refined `Linter.Config` type
8797
- */
8798
- type LinterConfig = TypedConfigItem;
8799
- /**
8800
- * ESLint rules
8801
- */
8802
- type RuleRecord = Linter.RulesRecord;
8803
- /**
8804
- * ESLint rules entry
8805
- */
8806
- type RuleRecordEntry = Record<string, RuleRecord>;
8807
-
8808
- /**
8809
- * @file Type Utils
9050
+ * Parser options
8810
9051
  */
8811
-
8812
- type Arrayable<T> = T | T[];
8813
- type Awaitable<T> = T | Promise<T>;
8814
- type InteropModuleDefault<T> = T extends {
8815
- default: infer U;
8816
- } ? U : T;
8817
- interface OverridesOptions<Rules = TypedConfigItem['rules']> {
8818
- files?: TypedConfigItem['files'];
8819
- rules?: Rules;
8820
- parserOptions?: ParserOptions;
8821
- }
8822
- type ResolvedOptions<T> = T extends boolean ? never : NonNullable<T>;
9052
+ type ParserOptions = Linter.ParserOptions;
8823
9053
 
8824
9054
  /**
8825
9055
  * @file Config options
@@ -8838,6 +9068,8 @@ interface OptionsOverrides<Rules extends TypedConfigItem['rules'] = TypedConfigI
8838
9068
  overrides?: Rules;
8839
9069
  }
8840
9070
  type ConfigIgnoresOptions = string[];
9071
+ type ConfigGitIgnoreOptions = FlatGitignoreOptions;
9072
+ type ConfigCommandOptions = ESLintPluginCommandOptions;
8841
9073
  interface ConfigJsdocOptions extends OptionsOverrides {
8842
9074
  }
8843
9075
  interface ConfigUnoCSSOptions extends OptionsOverrides {
@@ -8848,17 +9080,57 @@ interface ConfigImportsOptions extends OptionsOverrides {
8848
9080
  }
8849
9081
  interface ConfigNodeOptions extends OptionsOverrides {
8850
9082
  }
9083
+ interface ConfigAntfuOptions extends OptionsOverrides {
9084
+ }
8851
9085
  interface ConfigPrettierOptions extends OptionsOverrides {
9086
+ /**
9087
+ * Prettier level
9088
+ *
9089
+ * @default 'warn'
9090
+ */
9091
+ level?: 'warn' | 'error';
8852
9092
  }
9093
+ type PerfectionistSortType = 'alphabetical' | 'line-length' | 'natural';
9094
+ type PerfectionistSortOrder = 'asc' | 'desc';
8853
9095
  interface ConfigPerfectionistOptions extends OptionsOverrides {
9096
+ imports?: {
9097
+ type?: PerfectionistSortType;
9098
+ order?: PerfectionistSortOrder;
9099
+ };
9100
+ exports?: {
9101
+ type?: PerfectionistSortType;
9102
+ order?: PerfectionistSortOrder;
9103
+ };
9104
+ namedExports?: {
9105
+ type?: PerfectionistSortType;
9106
+ order?: PerfectionistSortOrder;
9107
+ };
9108
+ namedImports?: {
9109
+ type?: PerfectionistSortType;
9110
+ order?: PerfectionistSortOrder;
9111
+ };
8854
9112
  }
8855
9113
  interface ConfigCommentsOptions extends OptionsOverrides {
8856
9114
  }
8857
9115
  interface ConfigRegexpOptions extends OptionsOverrides {
8858
9116
  }
8859
9117
  interface ConfigJavaScriptOptions extends OptionsOverrides {
9118
+ /**
9119
+ * Enable strict checking for JavaScript files
9120
+ *
9121
+ * @default false
9122
+ */
9123
+ strict?: boolean;
8860
9124
  }
8861
9125
  interface ConfigTypeScriptOptions extends OptionsOverrides {
9126
+ /**
9127
+ * Enable type aware check for TypeScript files
9128
+ */
9129
+ tsconfigPath?: string;
9130
+ /**
9131
+ * Additional parser options
9132
+ */
9133
+ parserOptions?: Partial<ParserOptions>;
8862
9134
  }
8863
9135
  interface ConfigJsoncOptions extends OptionsOverrides {
8864
9136
  }
@@ -8869,6 +9141,12 @@ interface ConfigMarkdownOptions extends OptionsOverrides {
8869
9141
  interface ConfigTomlOptions extends OptionsOverrides {
8870
9142
  }
8871
9143
  interface ConfigVueOptions extends OptionsOverrides {
9144
+ /**
9145
+ * Vue version
9146
+ *
9147
+ * @default 3
9148
+ */
9149
+ vueVersion?: 2 | 3;
8872
9150
  }
8873
9151
  interface ConfigVitestOptions extends OptionsOverrides {
8874
9152
  }
@@ -8878,24 +9156,27 @@ interface ConfigUnusedImportsOptions extends OptionsOverrides {
8878
9156
  * Config factory options
8879
9157
  */
8880
9158
  interface ConfigOptions {
8881
- command?: boolean;
8882
9159
  sortTsConfig?: boolean;
9160
+ sortI18nLocale?: boolean;
8883
9161
  sortPackageJson?: boolean;
8884
9162
  ignores?: ConfigIgnoresOptions;
9163
+ command?: boolean | ConfigCommandOptions;
9164
+ gitignore?: boolean | ConfigGitIgnoreOptions;
8885
9165
  imports?: ConfigImportsOptions;
8886
- javascript?: ConfigJavaScriptOptions;
8887
- typescript?: ConfigTypeScriptOptions;
8888
9166
  node?: ConfigNodeOptions;
9167
+ javascript?: ConfigJavaScriptOptions;
9168
+ typescript?: boolean | ConfigTypeScriptOptions;
8889
9169
  unicorn?: boolean | ConfigUnicornOptions;
8890
9170
  prettier?: boolean | ConfigPrettierOptions;
9171
+ perfectionist?: boolean | ConfigPerfectionistOptions;
8891
9172
  /**
8892
9173
  * @internal
8893
9174
  */
8894
- perfectionist?: boolean | ConfigPerfectionistOptions;
9175
+ unusedImports?: boolean | ConfigUnusedImportsOptions;
8895
9176
  /**
8896
9177
  * @internal
8897
9178
  */
8898
- unusedImports?: boolean | ConfigUnusedImportsOptions;
9179
+ antfu?: boolean | ConfigAntfuOptions;
8899
9180
  comments?: boolean | ConfigCommentsOptions;
8900
9181
  jsdoc?: boolean | ConfigJsdocOptions;
8901
9182
  unocss?: boolean | ConfigUnoCSSOptions;
@@ -8915,32 +9196,7 @@ interface ConfigOptions {
8915
9196
  /**
8916
9197
  * Config factory
8917
9198
  */
8918
- declare function ntnyq(options?: ConfigOptions, customConfig?: Arrayable<TypedConfigItem>): TypedConfigItem[];
8919
-
8920
- declare const hasTypeScript: boolean;
8921
- declare const hasVitest: boolean;
8922
- declare const hasVue: boolean;
8923
- declare const hasUnoCSS: boolean;
8924
-
8925
- declare function toArray<T>(val?: Arrayable<T>): T[];
8926
-
8927
- /**
8928
- * Load an ESLint plugin by name.
8929
- * @param name - The name of the plugin
8930
- * @returns The plugin module
8931
- */
8932
- declare function loadPlugin<T = unknown>(name: string): Promise<T>;
8933
-
8934
- declare function getOverrides<K extends keyof ConfigOptions>(options: ConfigOptions, key: K): Partial<RuleRecord & RuleOptions>;
8935
-
8936
- /**
8937
- * Interop default export from a module
8938
- * @param mod - The module
8939
- * @returns The default export
8940
- */
8941
- declare function interopDefault<T>(mod: Awaitable<T>): Promise<InteropModuleDefault<T>>;
8942
-
8943
- declare function resolveSubOptions<K extends keyof ConfigOptions>(options: ConfigOptions, key: K): ResolvedOptions<ConfigOptions[K]>;
9199
+ declare function ntnyq(options?: ConfigOptions, userConfigs?: Arrayable<TypedConfigItem>): FlatConfigComposer<TypedConfigItem, ConfigNames>;
8944
9200
 
8945
9201
  /**
8946
9202
  * @file globs constants
@@ -8952,7 +9208,7 @@ declare const GLOB_JSX = "**/*.?([cm])jsx";
8952
9208
  declare const GLOB_TS = "**/*.?([cm])ts";
8953
9209
  declare const GLOB_TSX = "**/*.?([cm])tsx";
8954
9210
  declare const GLOB_DTS = "**/*.d.?([cm])ts";
8955
- declare const GLOB_TEST = "**/*.{test,spec}.?([cm])[jt]s?(x)";
9211
+ declare const GLOB_TEST = "**/*.{test,spec,bench,benchmark}.?([cm])[jt]s?(x)";
8956
9212
  declare const GLOB_STYLE = "**/*.{c,le,sc}ss";
8957
9213
  declare const GLOB_CSS = "**/*.css";
8958
9214
  declare const GLOB_LESS = "**/*.less";
@@ -8961,63 +9217,94 @@ declare const GLOB_JSON = "**/*.json";
8961
9217
  declare const GLOB_JSON5 = "**/*.json5";
8962
9218
  declare const GLOB_JSONC = "**/*.jsonc";
8963
9219
  declare const GLOB_VUE = "**/*.vue";
8964
- declare const GLOB_MARKDOWN = "**/*.md";
8965
9220
  declare const GLOB_YAML = "**/*.y?(a)ml";
8966
9221
  declare const GLOB_TOML = "**/*.toml";
8967
9222
  declare const GLOB_HTML = "**/*.htm?(l)";
9223
+ declare const GLOB_MARKDOWN = "**/*.md";
9224
+ declare const GLOB_MARKDOWN_CODE = "**/*.md/**/*.?([cm])[jt]s?(x)";
9225
+ declare const GLOB_MARKDOWN_NESTED = "**/*.md/*.md";
8968
9226
  declare const GLOB_ALL_SRC: string[];
8969
9227
  declare const GLOB_NODE_MODULES = "**/node_modules/**";
8970
9228
  declare const GLOB_DIST = "**/dist/**";
8971
9229
  declare const GLOB_LOCKFILE: string[];
8972
9230
  declare const GLOB_EXCLUDE: string[];
8973
9231
 
9232
+ declare const hasTypeScript: boolean;
9233
+ declare const hasVitest: boolean;
9234
+ declare const hasVue: boolean;
9235
+ declare const hasUnoCSS: boolean;
9236
+
9237
+ declare function toArray<T>(val?: Arrayable<T>): T[];
9238
+
8974
9239
  /**
8975
- * @see https://eslint.org/docs/latest/use/configure/configuration-files-new#globally-ignoring-files-with-ignores
9240
+ * Load an ESLint plugin by name.
9241
+ * @param name - The name of the plugin
9242
+ * @returns The plugin module
8976
9243
  */
8977
- declare const ignores: (customIgnores?: ConfigIgnoresOptions) => LinterConfig[];
9244
+ declare function loadPlugin<T = unknown>(name: string): Promise<T>;
8978
9245
 
8979
- declare const node: (options?: ConfigNodeOptions) => LinterConfig[];
9246
+ declare function getOverrides<K extends keyof ConfigOptions>(options: ConfigOptions, key: K): Partial<TypedConfigItem['rules'] & RuleOptions>;
8980
9247
 
8981
- declare const jsdoc: (options?: ConfigJsdocOptions) => LinterConfig[];
9248
+ /**
9249
+ * Interop default export from a module
9250
+ * @param mod - The module
9251
+ * @returns The default export
9252
+ */
9253
+ declare function interopDefault<T>(mod: Awaitable<T>): Promise<InteropModuleDefault<T>>;
8982
9254
 
8983
- declare const imports: (options?: ConfigImportsOptions) => LinterConfig[];
9255
+ declare function resolveSubOptions<K extends keyof ConfigOptions>(options: ConfigOptions, key: K): ResolvedOptions<ConfigOptions[K]>;
8984
9256
 
8985
- declare const unicorn: (options?: ConfigUnicornOptions) => LinterConfig[];
9257
+ declare const vue: (options?: ConfigVueOptions) => TypedConfigItem[];
8986
9258
 
8987
- declare const prettier: (options?: ConfigPrettierOptions) => LinterConfig[];
9259
+ declare const yml: (options?: ConfigYmlOptions) => TypedConfigItem[];
8988
9260
 
8989
- declare const comments: (options?: ConfigCommentsOptions) => LinterConfig[];
9261
+ declare const node: (options?: ConfigNodeOptions) => TypedConfigItem[];
8990
9262
 
8991
- declare const javascript: (option?: ConfigJavaScriptOptions) => LinterConfig[];
8992
- declare const jsx: () => LinterConfig[];
9263
+ declare const sortPackageJson: () => TypedConfigItem[];
9264
+ declare const sortTsConfig: () => TypedConfigItem[];
9265
+ declare const sortI18nLocale: () => TypedConfigItem[];
8993
9266
 
8994
- declare const typescriptCore: (options?: ConfigTypeScriptOptions) => TypedConfigItem[];
8995
- declare const typescript: (options?: ConfigTypeScriptOptions) => LinterConfig[];
9267
+ declare const toml: (options?: ConfigTomlOptions) => TypedConfigItem[];
8996
9268
 
8997
- declare const unusedImports: (options?: ConfigUnusedImportsOptions) => LinterConfig[];
9269
+ declare const antfu: (options?: ConfigAntfuOptions) => TypedConfigItem[];
8998
9270
 
8999
- declare const perfectionist: (options?: ConfigPerfectionistOptions) => LinterConfig[];
9271
+ declare const jsdoc: (options?: ConfigJsdocOptions) => TypedConfigItem[];
9000
9272
 
9001
- declare const regexp: (options?: ConfigRegexpOptions) => LinterConfig[];
9273
+ declare const jsonc: (options?: ConfigJsoncOptions) => TypedConfigItem[];
9002
9274
 
9003
- declare const unocss: (options?: ConfigUnoCSSOptions) => LinterConfig[];
9275
+ declare const regexp: (options?: ConfigRegexpOptions) => TypedConfigItem[];
9004
9276
 
9005
- declare const command: () => LinterConfig[];
9277
+ declare const unocss: (options?: ConfigUnoCSSOptions) => TypedConfigItem[];
9006
9278
 
9007
- declare const vitest: (options?: ConfigVitestOptions) => LinterConfig[];
9279
+ declare const vitest: (options?: ConfigVitestOptions) => TypedConfigItem[];
9008
9280
 
9009
- declare function getVueVersion(): number;
9010
- declare const vue: (options?: ConfigVueOptions) => LinterConfig[];
9281
+ declare const command: (options?: ConfigCommandOptions) => TypedConfigItem[];
9011
9282
 
9012
- declare const yml: (options?: ConfigYmlOptions) => LinterConfig[];
9283
+ /**
9284
+ * @see https://eslint.org/docs/latest/use/configure/configuration-files-new#globally-ignoring-files-with-ignores
9285
+ */
9286
+ declare const ignores: (customIgnores?: ConfigIgnoresOptions) => TypedConfigItem[];
9013
9287
 
9014
- declare const toml: (options?: ConfigTomlOptions) => LinterConfig[];
9288
+ declare const imports: (options?: ConfigImportsOptions) => TypedConfigItem[];
9015
9289
 
9016
- declare const sortPackageJson: () => LinterConfig[];
9017
- declare const sortTsConfig: () => LinterConfig[];
9290
+ declare const unicorn: (options?: ConfigUnicornOptions) => TypedConfigItem[];
9291
+
9292
+ declare const comments: (options?: ConfigCommentsOptions) => TypedConfigItem[];
9293
+
9294
+ declare const markdown: (options?: ConfigMarkdownOptions) => TypedConfigItem[];
9295
+
9296
+ declare const prettier: (options?: ConfigPrettierOptions) => TypedConfigItem[];
9297
+
9298
+ declare const gitignore: (options?: ConfigGitIgnoreOptions) => TypedConfigItem[];
9299
+
9300
+ declare const javascript: (options?: ConfigJavaScriptOptions) => TypedConfigItem[];
9301
+ declare const jsx: () => TypedConfigItem[];
9302
+
9303
+ declare const typescriptCore: (options?: ConfigTypeScriptOptions) => TypedConfigItem[];
9304
+ declare const typescript: (options?: ConfigTypeScriptOptions) => TypedConfigItem[];
9018
9305
 
9019
- declare const jsonc: (options?: ConfigJsoncOptions) => LinterConfig[];
9306
+ declare const perfectionist: (options?: ConfigPerfectionistOptions) => TypedConfigItem[];
9020
9307
 
9021
- declare const markdown: (options?: ConfigMarkdownOptions) => LinterConfig[];
9308
+ declare const unusedImports: (options?: ConfigUnusedImportsOptions) => TypedConfigItem[];
9022
9309
 
9023
- export { type Arrayable, type Awaitable, type ConfigCommentsOptions, type ConfigIgnoresOptions, type ConfigImportsOptions, type ConfigJavaScriptOptions, type ConfigJsdocOptions, type ConfigJsoncOptions, type ConfigMarkdownOptions, type ConfigName, type ConfigNodeOptions, type ConfigOptions, type ConfigPerfectionistOptions, type ConfigPrettierOptions, type ConfigRegexpOptions, type ConfigTomlOptions, type ConfigTypeScriptOptions, type ConfigUnicornOptions, type ConfigUnoCSSOptions, type ConfigUnusedImportsOptions, type ConfigVitestOptions, type ConfigVueOptions, type ConfigYmlOptions, GLOB_ALL_SRC, GLOB_CSS, GLOB_DIST, GLOB_DTS, GLOB_EXCLUDE, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_LOCKFILE, GLOB_MARKDOWN, GLOB_NODE_MODULES, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_TEST, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_YAML, type InteropModuleDefault, type LinterConfig, type OptionsFiles, type OptionsOverrides, type OverridesOptions, type ParserOptions, type ResolvedOptions, type RuleOptions, type RuleRecord, type RuleRecordEntry, type Rules, type TypedConfigItem, command, comments, getOverrides, getVueVersion, hasTypeScript, hasUnoCSS, hasVitest, hasVue, ignores, imports, interopDefault, javascript, jsdoc, jsonc, jsx, loadPlugin, markdown, node, ntnyq, perfectionist, prettier, regexp, resolveSubOptions, sortPackageJson, sortTsConfig, toArray, toml, typescript, typescriptCore, unicorn, unocss, unusedImports, vitest, vue, yml };
9310
+ export { type Arrayable, type Awaitable, type ConfigAntfuOptions, type ConfigCommandOptions, type ConfigCommentsOptions, type ConfigGitIgnoreOptions, type ConfigIgnoresOptions, type ConfigImportsOptions, type ConfigJavaScriptOptions, type ConfigJsdocOptions, type ConfigJsoncOptions, type ConfigMarkdownOptions, type ConfigNames, type ConfigNodeOptions, type ConfigOptions, type ConfigPerfectionistOptions, type ConfigPrettierOptions, type ConfigRegexpOptions, type ConfigTomlOptions, type ConfigTypeScriptOptions, type ConfigUnicornOptions, type ConfigUnoCSSOptions, type ConfigUnusedImportsOptions, type ConfigVitestOptions, type ConfigVueOptions, type ConfigYmlOptions, GLOB_ALL_SRC, GLOB_CSS, GLOB_DIST, GLOB_DTS, GLOB_EXCLUDE, GLOB_HTML, GLOB_JS, GLOB_JSON, GLOB_JSON5, GLOB_JSONC, GLOB_JSX, GLOB_LESS, GLOB_LOCKFILE, GLOB_MARKDOWN, GLOB_MARKDOWN_CODE, GLOB_MARKDOWN_NESTED, GLOB_NODE_MODULES, GLOB_SCSS, GLOB_SRC, GLOB_SRC_EXT, GLOB_STYLE, GLOB_TEST, GLOB_TOML, GLOB_TS, GLOB_TSX, GLOB_VUE, GLOB_YAML, type InteropModuleDefault, type LiteralUnion, type OptionsFiles, type OptionsOverrides, type ParserOptions, type PerfectionistSortOrder, type PerfectionistSortType, type ResolvedOptions, type RuleOptions, type TypedConfigItem, antfu, command, comments, getOverrides, gitignore, hasTypeScript, hasUnoCSS, hasVitest, hasVue, ignores, imports, interopDefault, javascript, jsdoc, jsonc, jsx, loadPlugin, markdown, node, ntnyq, perfectionist, prettier, regexp, resolveSubOptions, sortI18nLocale, sortPackageJson, sortTsConfig, toArray, toml, typescript, typescriptCore, unicorn, unocss, unusedImports, vitest, vue, yml };