WP_Customize_Manager::add_customize_screen_to_heartbeat_settings() WordPress Method
The WP_Customize_Manager::add_customize_screen_to_heartbeat_settings() method allows you to add a customize screen to the heartbeat settings. This can be used to help improve the performance of the Customizer by reducing the number of requests that are made to the server.
WP_Customize_Manager::add_customize_screen_to_heartbeat_settings( array $settings ) #
Filters heartbeat settings for the Customizer.
Contents
Parameters
- $settings
(array)(Required)Current settings to filter.
Return
(array) Heartbeat settings.
Source
File: wp-includes/class-wp-customize-manager.php
public function add_customize_screen_to_heartbeat_settings( $settings ) { global $pagenow; if ( 'customize.php' === $pagenow ) { $settings['screenId'] = 'customize'; } return $settings; }
Expand full source codeCollapse full source codeView on TracView on GitHub
Changelog
Version | Description |
---|---|
4.9.0 | Introduced. |