Tells the script loader to load the scripts and styles of custom blocks if the widgets block editor is enabled.
$is_block_editor_screenboolrequired
public function should_load_block_editor_scripts_and_styles( $is_block_editor_screen ) {
if ( wp_use_widgets_block_editor() ) {
return true;
}
return $is_block_editor_screen;
}
| Version | Description |
|---|---|
| 5.8.0 | Introduced. |
© 2003–2024 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_customize_widgets/should_load_block_editor_scripts_and_styles