Dequeue the WordPress block editor stylesheet if the Classic Editor plugin is activated and configured
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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