Skip to content
This repository was archived by the owner on Mar 7, 2025. It is now read-only.

Commit 5bd65d9

Browse files
committed
Update graphql rules
1 parent edfaec4 commit 5bd65d9

File tree

4 files changed

+29
-5
lines changed

4 files changed

+29
-5
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
"tsconfig.json"
5252
],
5353
"devDependencies": {
54-
"@graphql-eslint/eslint-plugin": "~3.15.0",
54+
"@graphql-eslint/eslint-plugin": "~3.16.1",
5555
"@intlify/eslint-plugin-vue-i18n": "~2.0.0",
5656
"@poppinss/cliui": "~3.0.5",
5757
"@types/eslint": "~8.21.1",

pnpm-lock.yaml

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/rules/graphql-eslint/index.d.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ import type { RequireDeprecationReasonRule } from './require-deprecation-reason'
4242
import type { RequireDescriptionRule } from './require-description';
4343
import type { RequireFieldOfTypeQueryInMutationResultRule } from './require-field-of-type-query-in-mutation-result';
4444
import type { RequireIdWhenAvailableRule } from './require-id-when-available';
45+
import type { RequireImportFragmentRule } from './require-import-fragment';
4546
import type { RequireNullableFieldsWithOneofRule } from './require-nullable-fields-with-oneof';
4647
import type { RequireTypePatternWithOneofRule } from './require-type-pattern-with-oneof';
4748
import type { ScalarLeafsRule } from './scalar-leafs';
@@ -122,6 +123,7 @@ export type GraphQLRules = ExecutableDefinitionsRule &
122123
RequireDescriptionRule &
123124
RequireFieldOfTypeQueryInMutationResultRule &
124125
RequireIdWhenAvailableRule &
126+
RequireImportFragmentRule &
125127
RequireNullableFieldsWithOneofRule &
126128
RequireTypePatternWithOneofRule &
127129
SelectionSetDepthRule &
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
import type { RuleConfig } from '../rule-config';
2+
3+
/**
4+
* Require fragments to be imported via an import expression.
5+
*
6+
* @see [require-import-fragment](https://github.com/B2o5T/graphql-eslint/blob/master/docs/rules/require-import-fragment.md)
7+
*/
8+
export type RequireImportFragmentRuleConfig = RuleConfig<[]>;
9+
10+
/**
11+
* Require fragments to be imported via an import expression.
12+
*
13+
* @see [require-import-fragment](https://github.com/B2o5T/graphql-eslint/blob/master/docs/rules/require-import-fragment.md)
14+
*/
15+
export interface RequireImportFragmentRule {
16+
/**
17+
* Require fragments to be imported via an import expression.
18+
*
19+
* @see [require-import-fragment](https://github.com/B2o5T/graphql-eslint/blob/master/docs/rules/require-import-fragment.md)
20+
*/
21+
'@graphql-eslint/require-import-fragment': RequireImportFragmentRuleConfig;
22+
}

0 commit comments

Comments
 (0)