I don’t know if this is specifically a Gutenberg question, but this where I am encountering the need.
Two examples:
1) Field A is a dropdown populated with all post types. Field B is dropdown that lists all the posts for Field A.
2) Field A is a dropdown populated with all taxonomy types. Field B is dropdown that lists all the terms for Field A.
In both scenarios, when the user changes Field A, then the content of Field B would also change.
I’ve looked at the query filters to do something like this for the terms example:
function my_taxonomy_query( $args, $field, $post_id ) {
$args['taxonomy'] = get_field('taxonomies');
return $args;
}
add_filter('acf/fields/taxonomy/query/name=my_terms_field', 'my_taxonomy_query', 10, 3);
But no luck.
Thanks
Awesome, thanks, John. Will look into that.