Skip to content

Instantly share code, notes, and snippets.

@MBehtemam
Created December 1, 2018 08:02
Show Gist options
  • Save MBehtemam/eba6dbb4351ad1e4b2d03970962acb33 to your computer and use it in GitHub Desktop.
Save MBehtemam/eba6dbb4351ad1e4b2d03970962acb33 to your computer and use it in GitHub Desktop.
First Query
Field<TodoType>("todo", arguments: new QueryArguments(
new QueryArgument<NonNullGraphType<IntGraphType>> { Name = "id", Description = "id of todo" }
),
resolve: context => todoRepository.GetTodoById(context.GetArgument<int>("id")).Result
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment