I’m using TypeKit fonts on my site, so I don’t need to load the Lora and Oswald fonts from Google Fonts. I commented out the section in functions.php that loads the fonts, and I replaced all use of them in styles.css with my TypeKit fonts.
Yes, I still see them loading when I do a performance test using tools.pingdom.com.
What am I missing? Where else do I need to visit to disable Google Fonts?
Read Carrie’s blog here and see if this helps you. Be sure to read the comments.
Thanks for the post. Unfortunately, that doesn’t appear to address my problem. I already have the TypeKit fonts loaded and working. However, the Google Fonts are still part of my initial load time and I’m trying to trim them out. I didn’t see anything in the post that helped me completely rid the Google Fonts from loading.
Let me send a tweet out to Carrie.
Instead of commenting the line out in functions.php, go ahead and remove it completely. Not sure why it’s still loading with those lines commented out, but try it anyway.
Some of the older StudioPress themes used @import in style.css to bring in fonts versus the newer themes now all use the wp_enqueue_scripts function to load them. Since you’re using Eleven40 Pro, there shouldn’t be an @import in your stylesheet, but you might double-check just to be sure.
That worked. Not sure why. I figure commenting should have disabled it, but not so. Once I cut it out, the site stopped trying to load Google Fonts.
It’s insidious, those Google Fonts.
You must be logged in to reply to this topic.
Are you a blogger, web designer, developer, or website owner looking to generate more income?
Promote products for the largest and fastest growing online website platform as part of our affiliate program.