graphql_after_resolve_field

Fire an action AFTER the field resolves

do_action( 'graphql_after_resolve_field', mixed $source, array $args, AppContext $context, ResolveInfo $info, mixed $field_resolver, string $type_name, string $field_key, FieldDefinition $field, mixed $result );

Params

  • $source (mixed): The source passed down the Resolve Tree
  • $args (array): The args for the field
  • $context (AppContext): The AppContext that is passed down the resolve tree
  • $info (ResolveInfo): The ResolveInfo that is passed down the resolve tree
  • $field_resolver (mixed): The field resolver function
  • $type_name (string): The name of the type the fields belong to
  • $field_key (string): The name of the field
  • $field (FieldDefinition): The Field Definition for the resolving field
  • $result (mixed): The result of the field resolver

Source

File: wp-graphql/src/Utils/InstrumentSchema.php