From 7c0b0ace4dacbb581669f88b83b9643a83fc797a Mon Sep 17 00:00:00 2001 From: Eugen Wissner Date: Wed, 7 Oct 2020 05:24:51 +0200 Subject: Collect types once the schema is created --- docs/tutorial/tutorial.lhs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'docs/tutorial/tutorial.lhs') diff --git a/docs/tutorial/tutorial.lhs b/docs/tutorial/tutorial.lhs index 6a68e35..1024251 100644 --- a/docs/tutorial/tutorial.lhs +++ b/docs/tutorial/tutorial.lhs @@ -39,7 +39,7 @@ Now, as our first example, we are going to look at the example from First we build a GraphQL schema. > schema1 :: Schema IO -> schema1 = schema queryType +> schema1 = schema queryType Nothing Nothing mempty > > queryType :: ObjectType IO > queryType = ObjectType "Query" Nothing [] @@ -76,7 +76,7 @@ This runs the query by fetching the one field defined, returning For this example, we're going to be using time. > schema2 :: Schema IO -> schema2 = schema queryType2 +> schema2 = schema queryType2 Nothing Nothing mempty > > queryType2 :: ObjectType IO > queryType2 = ObjectType "Query" Nothing [] @@ -113,7 +113,7 @@ This runs the query, returning the current time Now that we have two resolvers, we can define a schema which uses them both. > schema3 :: Schema IO -> schema3 = schema queryType3 +> schema3 = schema queryType3 Nothing Nothing mempty > > queryType3 :: ObjectType IO > queryType3 = ObjectType "Query" Nothing [] $ HashMap.fromList -- cgit v1.2.3