Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/dazza-dev/sw-acf-options-graphql/archive/refs/heads/main.zipNo built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.
Dynamically exposes all ACF Options Page field groups via WPGraphQL with Polylang language support.
Description
This plugin bridges ACF Options Pages with WPGraphQL and Polylang, enabling translated options page fields in a headless WordPress setup.
It automatically discovers all ACF field groups assigned to Options Pages and registers them as root query fields in WPGraphQL, each with a language argument for Polylang translation support.
How it works:
- Scans all ACF field groups with
options_pagelocation rules - For each group, registers a GraphQL object type and root query field
- Uses the ACF
graphql_field_name(or generates one from the group title) - Sets Polylang language context before resolving fields via
get_field() - Works with ACF Options for Polylang for per-language option values
Example query:
{ sectionHeaders(language: ES) { featuresTitle featuresSubtitle plansTitle plansSubtitle } }
Requirements
Installation
- Upload the
sw-acf-options-graphqlfolder to/wp-content/plugins/ - Activate the plugin through the "Plugins" menu in WordPress
- Ensure ACF Options Pages have field groups with "Show in GraphQL" enabled
- Query your options via WPGraphQL with the
languageargument
Changelog
1.0.0
- Initial release
- Dynamic field group discovery from ACF Options Pages
- Polylang language support via acf-options-for-polylang
- Automatic snake_case to camelCase field name conversion
- ACF field type to GraphQL scalar type mapping