• Resolved Argentum

    (@argentum)


    Hello,

    I am trying to speed up the page and have removed all use of Font Awesome. Still at Pingdom Tools I get a warning:

    Resources with a “?” in the URL are not cached by some proxy caching servers. Remove the query string and encode the parameters into the URL for the following resources:

    https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css?ver=2.1.3.4
    https://use.fontawesome.com/releases/v5.0.13/css/all.css?ver=2.1.3.4

    I have searched the net and found a suggestion how to remove Font Awesome:

    
    /* TN Dequeue Styles - Remove Font Awesome from WordPress theme
    add_action( 'wp_print_styles', 'tn_dequeue_font_awesome_style' );
    function tn_dequeue_font_awesome_style() {
          wp_dequeue_style( 'fontawesome' );
          wp_deregister_style( 'fontawesome' );
    }
    
    add_filter( 'astra_enable_default_fonts', '__return_false' );
    

    Is it possible to remove Font Awesome?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Hello @argentum,

    Astra does not load FontAwesome to load the fonts. The fonts should be coming from some other plugin on your site.

    You can disable all plugins and enable them one-by-one to check which plugin is adding the fonts.

    Yes, it is possible, but if one of your plugins is loading Font Awesome, it might not be enough to deregister it as ‘fontawesome’.

    For example, the Instagram Feed plugin from Smash Balloon loads version 4.7 of Font Awesome. When you look inside the plugin’s folder in instagram-feed.php you’ll find:

    wp_enqueue_style( 'sb-font-awesome', 'https://maxcdn.bootstrapcdn.com/font-awesome/4.7.0/css/font-awesome.min.css', array(), '4.7.0' );

    To deregister just add the following to your functions.php:

    wp_dequeue_style( 'sb-font-awesome' );
    wp_deregister_style( 'sb-font-awesome' );
Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Remove loading of font awesome’ is closed to new replies.