WP_Customize_Code_Editor_Control::enqueue() WordPress Method

The WP_Customize_Code_Editor_Control::enqueue() method is used to enqueue the code editor control. This control is used to edit code in the WordPress Customizer. The code editor control provides syntax highlighting and error checking for the code being edited.

WP_Customize_Code_Editor_Control::enqueue() #

Enqueue control related scripts/styles.


Source

File: wp-includes/customize/class-wp-customize-code-editor-control.php

	public function enqueue() {
		$this->editor_settings = wp_enqueue_code_editor(
			array_merge(
				array(
					'type'       => $this->code_type,
					'codemirror' => array(
						'indentUnit' => 2,
						'tabSize'    => 2,
					),
				),
				$this->editor_settings
			)
		);
	}


Top ↑

Changelog

Changelog
VersionDescription
4.9.0Introduced.

The content displayed on this page has been created in part by processing WordPress source code files which are made available under the GPLv2 (or a later version) license by theĀ Free Software Foundation. In addition to this, the content includes user-written examples and information. All material is subject to review and curation by the WPPaste.com community.