WP_Customize_Partial::json()publicWP 4.5.0

Retrieves the data to export to the client via JSON.

Method of the class: WP_Customize_Partial{}

No Hooks.

Return

Array. Array of parameters passed to the JavaScript.

Usage

$WP_Customize_Partial = new WP_Customize_Partial();
$WP_Customize_Partial->json();

Changelog

Since 4.5.0 Introduced.

WP_Customize_Partial::json() code WP 6.5.2

public function json() {
	$exports = array(
		'settings'           => $this->settings,
		'primarySetting'     => $this->primary_setting,
		'selector'           => $this->selector,
		'type'               => $this->type,
		'fallbackRefresh'    => $this->fallback_refresh,
		'containerInclusive' => $this->container_inclusive,
	);
	return $exports;
}