diff --git a/angel_graphql/example/main.dart b/angel_graphql/example/main.dart index 4cb357ed..83e788bf 100644 --- a/angel_graphql/example/main.dart +++ b/angel_graphql/example/main.dart @@ -46,8 +46,13 @@ main() async { description: 'Modify the to-do list.', fields: [ field( - 'create', - graphQLString, + 'createTodo', + convertDartType(Todo), + inputs: [ + GraphQLFieldInput( + 'data', convertDartType(Todo).coerceToInputObject()), + ], + resolve: resolveViaServiceCreate(todoService), ), ], );