How to remove / engueue / de-register Google fonts in Cornerstone / X

Hello,

I can’t seem to get rid of the Raleway Google font from loading when Cornerstone plugin is active. I have tried solutions provided in the forums, going back from 2014 to the present. I can confirm that the unwanted fonts do NOT load when Cornerstone is deactivated. Google fonts slider in Typography is OFF

Fonts that load when Cornerstone plugin is active.

https://fonts.googleapis.com/css?family=Raleway:900,700&subset=latin,latin-ext -196ms

https://fonts.gstatic.com/s/raleway/v12/1Ptrg8zYS_SKggPNwJYtWqhPBg.woff -131ms

https://fonts.gstatic.com/s/raleway/v12/1Ptrg8zYS_SKggPNwK4vWqhPBg.woff - 37ms

Another font that is loaded and is independent from Cornerstone being active or not is
https://example.com/wp-content/themes/x/framework/fonts/font_awesome/fontawesome-webfont.woff2?v=4.7.0 - 68ms

WordPress 4.9.6 running X – Child Theme theme.
Installed Version 6.1.6 of X - STACK Ethos
Cornerstone Version 3.1.6 | By Themeco

Thanks in advance for providing a solution that doesn’t require breaching our site’s security.

Hi Jeremy,

If you have updated to X version 6.1.x and Cornerstone 3.1, you can fully disable Google Fonts without custom code, you can follow these steps:

  1. Go to Theme Options → Typography

  2. Enable use of the Font Manager

  3. Click the Settings icon in the Bar and navigate to Fonts

  4. Modify each font to reference a system font instead of a Google font

  5. After these changes are saved, no references will be made to Google Fonts on the front end of your site.

  6. Additionally, you can immediately force Google Fonts to not load by adding this code to functions.php of a child theme:

    add_filter( 'cs_load_google_fonts', '__return_false' );

https://theme.co/changelog/#theme-pro-2-1-0-theme-x-6-1-0-cornerstone-3-1-0

Hope this helps.

Used the font manager - Worked! Thanks

Is the font awesome part of X? Can it be removed?

Thanks

Hi There,

It is not recommended to remove any files on the theme because it will affect how your site is rendered. Fontawesome is the library of ICONS. Removing that means all icons use in the theme will jut display as square like below:

Please check this article instead for guidance on how to improve site performance.

Regards!

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.