How to remove dashicons.min.css from frontend?

Is there any way to remove the dashicons.min.css file from the frontend? I know that they are used by the admin panel, but my theme doesn’t use them so it’s an unnecessary request.

8

Try deregistering that stylesheet –

add_action( 'wp_print_styles',     'my_deregister_styles', 100 );

function my_deregister_styles()    { 
   //wp_deregister_style( 'amethyst-dashicons-style' ); 
   wp_deregister_style( 'dashicons' ); 


}

Leave a Comment