Skip to content

Commit 9d1ea7f

Browse files
committed
prettier update
1 parent 1e89062 commit 9d1ea7f

File tree

5 files changed

+12
-25
lines changed

5 files changed

+12
-25
lines changed

.prettierrc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{
2+
"printWidth": 100,
23
"trailingComma": "none",
34
"tabWidth": 2,
45
"semi": true,

graphql/generated/schemaType.ts

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,14 @@ export type Mutation = {
1919
addUser: User;
2020
};
2121

22-
2322
export type MutationAddProprietyArgs = {
2423
body?: InputMaybe<InputProprietyType>;
2524
};
2625

27-
2826
export type MutationAddReviewArgs = {
2927
body?: InputMaybe<InputReviewType>;
3028
};
3129

32-
3330
export type MutationAddUserArgs = {
3431
body?: InputMaybe<InputUserType>;
3532
};
@@ -56,17 +53,14 @@ export type Query = {
5653
userList: Array<User>;
5754
};
5855

59-
6056
export type QueryProprietyArgs = {
6157
id?: InputMaybe<Scalars['ID']>;
6258
};
6359

64-
6560
export type QueryReviewByUserArgs = {
6661
id?: InputMaybe<Scalars['ID']>;
6762
};
6863

69-
7064
export type QueryUserArgs = {
7165
id: Scalars['ID'];
7266
};

graphql/resolvers/propriety.ts

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,21 @@ import { resolverType } from 'fast-graphql';
33
import * as schemaType from '@/graphql/generated/schemaType';
44

55
const Query = {
6-
proprietyList: () => {
6+
proprietyList: (parent: any, args: any, ctx: any) => {
77
return [{ title: 'Nextjs' }];
88
},
99

10-
propriety: (
11-
parent: any,
12-
args: any,
13-
ctx: any
14-
): schemaType.Query['propriety'] => {
10+
propriety: (parent: any, args: any, ctx: any): schemaType.Query['propriety'] => {
1511
const { id } = args;
1612

1713
return { title: 'Nextjs', id };
18-
},
14+
}
1915
};
2016

2117
const Mutation = {
22-
addPropriety: (body: any): schemaType.Mutation['addPropriety'] => {
18+
addPropriety: (parent: any, args: any, ctx: any): schemaType.Mutation['addPropriety'] => {
2319
return { title: 'this is addPropriety mutuation' };
24-
},
20+
}
2521
};
2622

2723
const resolver: resolverType = { Query, Mutation };

graphql/resolvers/review.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@ import { resolverType } from 'fast-graphql';
33
const Query = {
44
reviewByUser: (id: any) => {
55
return { id: 'reviewByUser' };
6-
},
6+
}
77
};
88

99
const Mutation = {
1010
addReview: (body: any) => {
1111
return { name: 'this is addReview mutuation' };
12-
},
12+
}
1313
};
1414

1515
const resolver: resolverType = { Query, Mutation };

graphql/resolvers/user.ts

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,17 @@ const Query = {
77
return [{ email: 'Nextjs', id: 'sqdqsd', photo: 'qsdqsdqs' }];
88
},
99

10-
user: (
11-
_parent: any,
12-
_args: schemaType.QueryUserArgs,
13-
_context: any
14-
): schemaType.Query['user'] => {
15-
const { id } = _args;
10+
user: (parent: any, args: any, ctx: any): schemaType.Query['user'] => {
11+
const { id } = args;
1612
console.log('🚀 ~ file: user.ts ~ line 17 ~ id', id);
1713
return { email: 'Nextjs', id: 'sqdqsd', photo: 'qsdqsdqs' };
18-
},
14+
}
1915
};
2016

2117
const Mutation = {
2218
addUser: (body: any) => {
2319
return { name: 'this is addUser mutuation' };
24-
},
20+
}
2521
};
2622

2723
const resolver: resolverType = { Query, Mutation };

0 commit comments

Comments
 (0)