Enqueue styles in new site editor in WordPress 5.9
In the block editor for posts and pages, I used to use the enqueue_block_editor_assets
hook to enqueue styles for the block.
add_action( 'enqueue_block_editor_assets','load_assets_in_block' );
function load_assets_in_block() {
wp_enqueue_style(
'block-style',
plugins_url( 'assets/css/block-style.css', PLAYER_PLUGIN ),
array(),
PLAYER_PLUGIN_VERSION,
false
);
}
This still works on posts and pages block, but it isn't working on the new site editor in WordPress 5.9? What is the recommended way to enqueue styles in site editor?
Topic block-editor wp-enqueue-style css Wordpress
Category Web