Uses
Uses | Description |
---|---|
wp-includes/class-wp-block-type.php: WP_Block_Type::set_props() | Sets block type properties. |
Constructor.
Will populate object properties from the provided arguments.
(string) (Required) Block type name including namespace.
(array|string) (Optional) Array or string of arguments for registering a block type.
Default value: array()
File: wp-includes/class-wp-block-type.php
public function __construct( $block_type, $args = array() ) { $this->name = $block_type; $this->set_props( $args ); }
Version | Description |
---|---|
5.0.0 | Introduced. |
© 2003–2019 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_block_type/__construct