1
1
import js from '@eslint/js' ;
2
- import * as graphqlESLint from '@graphql-eslint/eslint-plugin' ;
2
+ import * as graphql from '@graphql-eslint/eslint-plugin' ;
3
3
4
4
const SCHEMA_PATH = 'server/**/*.gql' ;
5
5
@@ -11,7 +11,7 @@ export default [
11
11
{
12
12
files : [ 'client/**/*.tsx' ] ,
13
13
// Setup processor for operations/fragments definitions on code-files
14
- processor : graphqlESLint . processors . graphql ,
14
+ processor : graphql . processors . graphql ,
15
15
languageOptions : {
16
16
parserOptions : {
17
17
sourceType : 'module' ,
@@ -25,20 +25,20 @@ export default [
25
25
// Setup GraphQL Parser
26
26
files : [ '**/*.{graphql,gql}' ] ,
27
27
plugins : {
28
- '@graphql-eslint' : graphqlESLint ,
28
+ '@graphql-eslint' : { rules : graphql . rules } ,
29
29
} ,
30
30
languageOptions : {
31
- parser : graphqlESLint ,
31
+ parser : graphql . parser ,
32
32
} ,
33
33
} ,
34
34
{
35
35
// Setup recommended config for schema files
36
36
files : [ SCHEMA_PATH ] ,
37
- ...graphqlESLint . flatConfigs [ 'schema-recommended' ] ,
37
+ ...graphql . flatConfigs [ 'schema-recommended' ] ,
38
38
} ,
39
39
{
40
40
// Setup recommended config for operations files
41
41
files : [ 'client/**/*.{graphql,gql}' ] ,
42
- ...graphqlESLint . flatConfigs [ 'operations-recommended' ] ,
42
+ ...graphql . flatConfigs [ 'operations-recommended' ] ,
43
43
} ,
44
44
] ;
0 commit comments