Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Dequeue the WordPress block editor stylesheet if the Classic Editor plugin is activated and configured
add_action( 'wp_enqueue_scripts', 'simon_dequeue_block_editor_styles' );
function simon_dequeue_block_editor_styles() {
if ( 'classic' === get_option( 'classic-editor-replace' ) ) {
wp_dequeue_style( 'wp-block-library' );
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.