Skip to content

Instantly share code, notes, and snippets.

@someguy9
Last active November 21, 2023 08:00
Show Gist options
  • Select an option

  • Save someguy9/1f51a7cb3349cc32d00f5aaa5d3b3e19 to your computer and use it in GitHub Desktop.

Select an option

Save someguy9/1f51a7cb3349cc32d00f5aaa5d3b3e19 to your computer and use it in GitHub Desktop.

Revisions

  1. someguy9 revised this gist Jan 28, 2022. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion wp-remove-gutenberg-block-library-css.php
    Original file line number Diff line number Diff line change
    @@ -3,6 +3,6 @@
    function smartwp_remove_wp_block_library_css(){
    wp_dequeue_style( 'wp-block-library' );
    wp_dequeue_style( 'wp-block-library-theme' );
    wp_dequeue_style( 'wc-block-style' ); // Remove WooCommerce block CSS
    wp_dequeue_style( 'wc-blocks-style' ); // Remove WooCommerce block CSS
    }
    add_action( 'wp_enqueue_scripts', 'smartwp_remove_wp_block_library_css', 100 );
  2. someguy9 revised this gist May 17, 2020. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion wp-remove-gutenberg-block-library-css.php
    Original file line number Diff line number Diff line change
    @@ -3,5 +3,6 @@
    function smartwp_remove_wp_block_library_css(){
    wp_dequeue_style( 'wp-block-library' );
    wp_dequeue_style( 'wp-block-library-theme' );
    wp_dequeue_style( 'wc-block-style' ); // Remove WooCommerce block CSS
    }
    add_action( 'wp_enqueue_scripts', 'smartwp_remove_wp_block_library_css' );
    add_action( 'wp_enqueue_scripts', 'smartwp_remove_wp_block_library_css', 100 );
  3. someguy9 revised this gist Jan 14, 2020. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions wp-remove-gutenberg-block-library-css.php
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,5 @@
    <?php
    //Remove Gutenberg Block Library CSS from loading on the frontend
    function smartwp_remove_wp_block_library_css(){
    wp_dequeue_style( 'wp-block-library' );
    wp_dequeue_style( 'wp-block-library-theme' );
  4. someguy9 revised this gist Jan 14, 2020. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions wp-remove-gutenberg-block-library-css.php
    Original file line number Diff line number Diff line change
    @@ -1,5 +1,6 @@
    <?php
    function smartwp_remove_wp_block_library_css(){
    wp_dequeue_style( 'wp-block-library' );
    wp_dequeue_style( 'wp-block-library-theme' );
    }
    add_action( 'wp_enqueue_scripts', 'smartwp_remove_wp_block_library_css' );
  5. someguy9 created this gist Jul 1, 2019.
    5 changes: 5 additions & 0 deletions wp-remove-gutenberg-block-library-css.php
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,5 @@
    <?php
    function smartwp_remove_wp_block_library_css(){
    wp_dequeue_style( 'wp-block-library' );
    }
    add_action( 'wp_enqueue_scripts', 'smartwp_remove_wp_block_library_css' );