From 92b07f9325d23d194bbc44144e7a03f67342fc96 Mon Sep 17 00:00:00 2001 From: "hugo.prunaux" Date: Sun, 15 Dec 2024 12:08:01 +0100 Subject: [PATCH] refactor: renames `builtTypeJsonSchema` to `buildTypeJsonSchema` --- rules/sort-array-includes.ts | 4 ++-- rules/sort-classes.ts | 4 ++-- rules/sort-decorators.ts | 4 ++-- rules/sort-enums.ts | 4 ++-- rules/sort-exports.ts | 4 ++-- rules/sort-heritage-clauses.ts | 4 ++-- rules/sort-imports.ts | 4 ++-- rules/sort-intersection-types.ts | 4 ++-- rules/sort-jsx-props.ts | 4 ++-- rules/sort-maps.ts | 4 ++-- rules/sort-modules.ts | 4 ++-- rules/sort-named-exports.ts | 4 ++-- rules/sort-named-imports.ts | 4 ++-- rules/sort-object-types.ts | 4 ++-- rules/sort-objects.ts | 4 ++-- rules/sort-switch-case.ts | 4 ++-- rules/sort-union-types.ts | 4 ++-- rules/sort-variable-declarations.ts | 4 ++-- utils/common-json-schemas.ts | 2 +- 19 files changed, 37 insertions(+), 37 deletions(-) diff --git a/rules/sort-array-includes.ts b/rules/sort-array-includes.ts index efa9e3ad1..6fc52a676 100644 --- a/rules/sort-array-includes.ts +++ b/rules/sort-array-includes.ts @@ -13,7 +13,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -90,7 +90,7 @@ export let jsonSchema: JSONSchema4 = { singleCustomGroupJsonSchema, }), useConfigurationIf: buildUseConfigurationIfJsonSchema(), - type: builtTypeJsonSchema({ withUnsorted: true }), + type: buildTypeJsonSchema({ withUnsorted: true }), partitionByNewLine: partitionByNewLineJsonSchema, specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, diff --git a/rules/sort-classes.ts b/rules/sort-classes.ts index 9b813854f..db3fd280f 100644 --- a/rules/sort-classes.ts +++ b/rules/sort-classes.ts @@ -15,7 +15,7 @@ import { specialCharactersJsonSchema, newlinesBetweenJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -694,7 +694,7 @@ export default createEslintRule({ newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-decorators.ts b/rules/sort-decorators.ts index 1ca779fc5..a868e31d5 100644 --- a/rules/sort-decorators.ts +++ b/rules/sort-decorators.ts @@ -8,7 +8,7 @@ import { specialCharactersJsonSchema, customGroupsJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -116,7 +116,7 @@ export default createEslintRule, MESSAGE_ID>({ customGroups: customGroupsJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-enums.ts b/rules/sort-enums.ts index 603553fb5..3d3250c85 100644 --- a/rules/sort-enums.ts +++ b/rules/sort-enums.ts @@ -8,7 +8,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -282,7 +282,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-exports.ts b/rules/sort-exports.ts index 7b3dda176..0a7aff295 100644 --- a/rules/sort-exports.ts +++ b/rules/sort-exports.ts @@ -7,7 +7,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -197,7 +197,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-heritage-clauses.ts b/rules/sort-heritage-clauses.ts index 9c4c26912..d1454dcfa 100644 --- a/rules/sort-heritage-clauses.ts +++ b/rules/sort-heritage-clauses.ts @@ -7,7 +7,7 @@ import { specialCharactersJsonSchema, customGroupsJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -69,7 +69,7 @@ export default createEslintRule, MESSAGE_ID>({ customGroups: customGroupsJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-imports.ts b/rules/sort-imports.ts index 73329d947..5ca40c4d6 100644 --- a/rules/sort-imports.ts +++ b/rules/sort-imports.ts @@ -10,7 +10,7 @@ import { specialCharactersJsonSchema, newlinesBetweenJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -635,7 +635,7 @@ export default createEslintRule, MESSAGE_ID>({ newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-intersection-types.ts b/rules/sort-intersection-types.ts index ef56082ed..aacdc0355 100644 --- a/rules/sort-intersection-types.ts +++ b/rules/sort-intersection-types.ts @@ -6,7 +6,7 @@ import { specialCharactersJsonSchema, newlinesBetweenJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -302,7 +302,7 @@ export default createEslintRule({ newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-jsx-props.ts b/rules/sort-jsx-props.ts index a9ba9396d..c84ed3244 100644 --- a/rules/sort-jsx-props.ts +++ b/rules/sort-jsx-props.ts @@ -6,7 +6,7 @@ import { specialCharactersJsonSchema, customGroupsJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -205,7 +205,7 @@ export default createEslintRule, MESSAGE_ID>({ customGroups: customGroupsJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-maps.ts b/rules/sort-maps.ts index ff04e6abf..446fc51de 100644 --- a/rules/sort-maps.ts +++ b/rules/sort-maps.ts @@ -7,7 +7,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -199,7 +199,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-modules.ts b/rules/sort-modules.ts index 08cd84488..2edf0457e 100644 --- a/rules/sort-modules.ts +++ b/rules/sort-modules.ts @@ -17,7 +17,7 @@ import { specialCharactersJsonSchema, newlinesBetweenJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -117,7 +117,7 @@ export default createEslintRule({ newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-named-exports.ts b/rules/sort-named-exports.ts index 8aab2eadf..07a9d305e 100644 --- a/rules/sort-named-exports.ts +++ b/rules/sort-named-exports.ts @@ -7,7 +7,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -199,7 +199,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-named-imports.ts b/rules/sort-named-imports.ts index 21e11b69f..a3bdce20e 100644 --- a/rules/sort-named-imports.ts +++ b/rules/sort-named-imports.ts @@ -7,7 +7,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -212,7 +212,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-object-types.ts b/rules/sort-object-types.ts index 0786d9f1b..18e3506bd 100644 --- a/rules/sort-object-types.ts +++ b/rules/sort-object-types.ts @@ -13,7 +13,7 @@ import { newlinesBetweenJsonSchema, customGroupsJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -112,7 +112,7 @@ export let jsonSchema: JSONSchema4 = { newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-objects.ts b/rules/sort-objects.ts index b8cf5d0f5..767b28212 100644 --- a/rules/sort-objects.ts +++ b/rules/sort-objects.ts @@ -10,7 +10,7 @@ import { newlinesBetweenJsonSchema, customGroupsJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -552,7 +552,7 @@ export default createEslintRule({ description: 'Controls whether to sort styled components.', type: 'boolean', }, - type: builtTypeJsonSchema({ withUnsorted: true }), + type: buildTypeJsonSchema({ withUnsorted: true }), partitionByNewLine: partitionByNewLineJsonSchema, specialCharacters: specialCharactersJsonSchema, newlinesBetween: newlinesBetweenJsonSchema, diff --git a/rules/sort-switch-case.ts b/rules/sort-switch-case.ts index 049768044..c9964e362 100644 --- a/rules/sort-switch-case.ts +++ b/rules/sort-switch-case.ts @@ -6,7 +6,7 @@ import type { SortingNode } from '../typings' import { specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -270,7 +270,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/rules/sort-union-types.ts b/rules/sort-union-types.ts index 43c25df1d..d10801eab 100644 --- a/rules/sort-union-types.ts +++ b/rules/sort-union-types.ts @@ -6,7 +6,7 @@ import { specialCharactersJsonSchema, newlinesBetweenJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, groupsJsonSchema, @@ -301,7 +301,7 @@ export default createEslintRule({ newlinesBetween: newlinesBetweenJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, groups: groupsJsonSchema, order: orderJsonSchema, diff --git a/rules/sort-variable-declarations.ts b/rules/sort-variable-declarations.ts index 437f567a2..872f13dcd 100644 --- a/rules/sort-variable-declarations.ts +++ b/rules/sort-variable-declarations.ts @@ -7,7 +7,7 @@ import { partitionByNewLineJsonSchema, specialCharactersJsonSchema, ignoreCaseJsonSchema, - builtTypeJsonSchema, + buildTypeJsonSchema, alphabetJsonSchema, localesJsonSchema, orderJsonSchema, @@ -289,7 +289,7 @@ export default createEslintRule({ specialCharacters: specialCharactersJsonSchema, ignoreCase: ignoreCaseJsonSchema, alphabet: alphabetJsonSchema, - type: builtTypeJsonSchema(), + type: buildTypeJsonSchema(), locales: localesJsonSchema, order: orderJsonSchema, }, diff --git a/utils/common-json-schemas.ts b/utils/common-json-schemas.ts index cf73d6594..e2b3e5009 100644 --- a/utils/common-json-schemas.ts +++ b/utils/common-json-schemas.ts @@ -1,6 +1,6 @@ import type { JSONSchema4 } from '@typescript-eslint/utils/json-schema' -export let builtTypeJsonSchema = ({ +export let buildTypeJsonSchema = ({ withUnsorted, }: { withUnsorted?: boolean } = {}): JSONSchema4 => { let enumValues = ['alphabetical', 'natural', 'line-length', 'custom']