WP_REST_View_Config_Controller::get_list_layout_schema
Returns the layout schema for list-type views (ViewList, ViewActivity).
Method of the class: WP_REST_View_Config_Controller{}
No Hooks.
Returns
array. Schema for a list layout object.
Usage
// protected - for code of main (parent) or child class $result = $this->get_list_layout_schema();
Changelog
| Since 7.1.0 | Introduced. |
WP_REST_View_Config_Controller::get_list_layout_schema() WP REST View Config Controller::get list layout schema code WP 7.1.2
protected function get_list_layout_schema() {
return array(
'type' => 'object',
'properties' => array(
'density' => array(
'type' => 'string',
'enum' => array( 'compact', 'balanced', 'comfortable' ),
),
),
);
}