josephfusco/wpgraphiql-query-injector
最新稳定版本:1.0.0
Composer 安装命令:
composer require josephfusco/wpgraphiql-query-injector
包简介
Inject a custom query and variables into the WPGraphiQL editor
README 文档
README
Overview
WPGraphiQL Query Injector is a WordPress plugin designed to inject custom GraphQL queries and variables into your WPGraphiQL editor. The plugin aims to provide a straightforward way to populate the WPGraphiQL editor within a WordPress Playground environment.
Usage
Once the plugin is activated, it will automatically populate the WPGraphiQL editor with predefined queries and variables. You can modify these by applying WordPress filters.
Filters
wpgraphiql_query
Filter the GraphiQL Query input.
add_filter( 'wpgraphiql_query', function() { return <<<GRAPHQL query GeneralSettings { allSettings { siteTitle: generalSettingsTitle sideDescription: generalSettingsDescription } } GRAPHQL });
wpgraphiql_variables
Filter the GraphiQL Variables input.
add_filter( 'wpgraphiql_variables', function() { return <<<JSON { "id": 716 } JSON; });
wpgraphiql_use_public_fetcher
Filter auth vs public requests.
add_filter( 'wpgraphiql_use_public_fetcher', function() { return 'true'; });
统计信息
- 总下载量: 4
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-or-later
- 更新时间: 2023-10-22