-
Notifications
You must be signed in to change notification settings - Fork 4.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enabling Gutenberg breaks hook in the customizer #25417
Comments
Hi there! We'd need more information if you want us to help you. |
I connect some scripts on the admin_enqueue_scripts hook that I use on all admin pages, but when the gutenberg plugin is activated, this hook does not work for me on the Customize page (wp-admin / customize.php), but although it does work before activation |
@dimaeromin97 Just to make sure I understand properly, is it the only script that doesn't work? or any hook loaded on I wonder if this is related to the block-based customizer panel. cc @adamziel |
Blocked by #25625 |
We'll be completely rearchitecting our implementation of how blocks work in the Customizer, but in the meantime let's investigate this to see if this hook is not being fired when the Gutenberg plugin is active. If so then let's fix that asap. |
This is not blocked anymore. I think #25415 is related too. |
I'm not able to reproduce this. I created a plugin with the following files, activated Gutenberg, enabled the Widgets in Customizer experiment, navigated to Appearance → Customize, and saw the alert dialog appear. // my-plugin/my-plugin.php
/**
* Plugin Name: My plugin
*/
add_action(
'admin_enqueue_scripts',
function() {
wp_enqueue_script( 'my-script', plugin_dir_url( __FILE__ ) . 'my-script.js', array(), '1.0' );
}
); // my-plugin/my-script.js
alert( 'hello!' ); Let me know if I've misunderstood and we can reopen. |
is this still a thing? |
Describe the bug
Action
admin_enqueue_scripts
on customize.php does not work on the customizer admin screen when the Gutenberg plugin is activated.To reproduce
Steps to reproduce the behavior:
admin_enqueue_scripts
Editor version (please complete the following information):
Desktop (please complete the following information):
The text was updated successfully, but these errors were encountered: