WordPress at Your Fingertips
function is not described

WP_Screen::add_option() public WP 3.3.0

Adds an option for the screen.

Call this in template files after admin.php is loaded and before admin-header.php is loaded to add screen options.

{} It's a method of the class: WP_Screen{}

No Hooks.

Return

null. Nothing.

Usage

$WP_Screen = new WP_Screen();
$WP_Screen->add_option( $option, $args );
$option(string) (required)
Option ID.
$args(mixed)
Option-dependent arguments.
Default: array()

Changelog

Since 3.3.0 Introduced.

Code of WP_Screen::add_option() WP 5.8.2

public function add_option( $option, $args = array() ) {
	$this->_options[ $option ] = $args;
}