WP_REST_Term_Meta_Fields::get_rest_field_type()
Retrieves the type for register_rest_field().
Return
(string) The REST field type.
Source
File: wp-includes/rest-api/fields/class-wp-rest-term-meta-fields.php
public function get_rest_field_type() { return 'post_tag' === $this->taxonomy ? 'tag' : $this->taxonomy; }
Changelog
Version | Description |
---|---|
4.7.0 | Introduced. |
© 2003–2021 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_rest_term_meta_fields/get_rest_field_type