WP_Screen::is_block_editor

Advertisement

Summery Summery

Sets or returns whether the block editor is loading on the current screen.

Syntax Syntax

WP_Screen::is_block_editor( bool $set = null )

Parameters Parameters

$set

(Optional) Sets whether the block editor is loading on the current screen or not.

Default value: null

Return Return

(bool) True if the block editor is being loaded, false otherwise.

Source Source

File: wp-admin/includes/class-wp-screen.php

	public function is_block_editor( $set = null ) {
		if ( null !== $set ) {
			$this->is_block_editor = (bool) $set;
		}

		return $this->is_block_editor;
	}

Advertisement

Changelog Changelog

Changelog
Version Description
5.0.0 Introduced.

Advertisement

Leave a Reply