Editor: Ensure block script is enqueued, regardless of ronder_callback.
Follow-up to [54155]. Props aristath, cbravobernal. See #56408. Built from https://develop.svn.wordpress.org/trunk@54367 git-svn-id: http://core.svn.wordpress.org/trunk@53926 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -266,7 +266,7 @@ class WP_Block {
|
||||
}
|
||||
}
|
||||
|
||||
if ( ! empty( $this->block_type->view_script_handles ) && empty( $this->block_type->render_callback ) ) {
|
||||
if ( ! empty( $this->block_type->view_script_handles ) ) {
|
||||
foreach ( $this->block_type->view_script_handles as $view_script_handle ) {
|
||||
wp_enqueue_script( $view_script_handle );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user