Skip to content

Commit 2fa2ad3

Browse files
committed
wrote out all af the possible graphql types and how they relate to the typeWeightCOnfig object
1 parent 0ff813b commit 2fa2ad3

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/analysis/buildTypeWeights.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,11 @@ import { GraphQLSchema } from 'graphql/type/schema';
1515
function buildTypeWeightsFromSchema(
1616
schema: GraphQLSchema,
1717
typeWeightsConfig: TypeWeightConfig = {
18-
mutation: 10,
19-
object: 1,
20-
scalar: 0,
21-
connection: 2,
18+
mutation: 10, // mutation
19+
object: 1, // itnterfaces, unions, objects, query
20+
scalar: 0, // enums, scalars
21+
connection: 2, // pagination stuff
22+
// ? subscription
2223
}
2324
): TypeWeightObject {
2425
throw Error(`getTypeWeightsFromSchema is not implemented.`);

0 commit comments

Comments
 (0)