跳转到主要内容

0252-filters-graphql-should-analyze-query


title: graphql_should_analyze_query hookType: filter hookGroup: debugging plugin: wp-graphql

graphql_should_analyze_query

apply_filters( 'graphql_should_analyze_query', $is_enabled, $this->get_request() );

Filters whether to analyze queries or for a specific GraphQL request.

  • Type: filter
  • Group: Debugging and Instrumentation
  • Since: 1.11.0
  • Source File: plugins/wp-graphql/src/Utils/QueryAnalyzer.php

Parameters

  • $should_analyze_queries (bool): Whether to analyze queries for the current request. Defaults to the value of graphql_query_analyzer_enabled filter.
  • $request (\WPGraphQL\Request): The GraphQL request being executed.

Source

apply_filters( 'graphql_should_analyze_query', $is_enabled, $this->get_request() );