-
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
enqueue_block_editor_assets is not fired on /wp-admin/themes.php?page=gutenberg-widgets #28538
Comments
I am able to work around this by adding
to the beginning of the function and hooking into enqueue_block_assets instead of enqueue_block_editor_assets i'm not sure if this is the ideal solution though. |
if it helps - I'm not familiar with the wordpress core codebase at all, but - i searched my folder for 'enqueue_block_editor_assets' and found only one instance where its explicitly triggered by a call to do_action in edit-form-blocks.php on line 395 |
I verified that |
Following up on this, @noisysocks noted that
A documentation issue to help clarify what filters are available in what contexts is being tracked here: #28710 |
Ok but I am not using an old filter, i am trying to use the 'enqueue_block_editor_assets' filter so that my custom blocks are usable on the widgets screen. |
I can confirm that Whether it should be called in these screens is an interesting question. I think it probably makes sense for there to be a generic But I know that we already have a few related actions and filters e.g. |
I am closing this in favor of #25945 as the reason is the page not being found as an admin page. Will port @noisysocks 's comment over. |
Description
the enqueue_block_editor_assets action is not fired on the widget editor screen defined by the gutenberg plugin
Step-by-step reproduction instructions
write a function to be called when enqueue_block_editor_assets is triggered like:
Expected behaviour
It should display a white screen with the message shown above
Actual behaviour
The widget editor screen loads as normal, any custom scripts enqueued in the function above will not actually load
WordPress information
Device information
The text was updated successfully, but these errors were encountered: