Title: Optimize Google Font
Last modified: June 5, 2019

---

# Optimize Google Font

 *  Resolved [andcha](https://wordpress.org/support/users/andcha/)
 * (@andcha)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/optimize-google-font/)
 * In reference to this post about adding css font-display:swap
    [https://wordpress.org/support/topic/optimising-font-performance/](https://wordpress.org/support/topic/optimising-font-performance/)
 * Just FYI [@nikschavan](https://wordpress.org/support/users/nikschavan/), font-
   display issue was resolved few weeks ago in May 2019
    [https://github.com/google/fonts/issues/358#issuecomment-491453043](https://github.com/google/fonts/issues/358#issuecomment-491453043)
 * [https://github.com/brainstormforce/astra/blob/8b2207141fcd78d9c90bc15d33cf6325fd77dba9/inc/customizer/class-astra-fonts.php](https://github.com/brainstormforce/astra/blob/8b2207141fcd78d9c90bc15d33cf6325fd77dba9/inc/customizer/class-astra-fonts.php)
   
   Is this the file responsible for sending css font request to google? If yes, 
   is there anyway we can temporarily fix the request url till an update is pushed?

Viewing 2 replies - 1 through 2 (of 2 total)

 *  [Nikhil Chavan](https://wordpress.org/support/users/nikschavan/)
 * (@nikschavan)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/optimize-google-font/#post-11607512)
 * Hello [@andcha](https://wordpress.org/support/users/andcha/),
 * From Astra we are have started adding `font-display: swap` property for Google
   fonts as soon as they released this from Google fonts API. `fallback` was selected
   as a default `font-display` attribute after some research as a sane default.
 * In the upcoming udpate of Astra, we are also [adding a filter](https://github.com/brainstormforce/astra/pull/1174/files)
   to allow users to change this to `swap` or any other attributes.
 *  Thread Starter [andcha](https://wordpress.org/support/users/andcha/)
 * (@andcha)
 * [6 years, 10 months ago](https://wordpress.org/support/topic/optimize-google-font/#post-11607633)
 * Thanks [@nikschavan](https://wordpress.org/support/users/nikschavan/) for super
   duper quick reply. Meanwhile I came across this improvement by premanshup on 
   github: [https://github.com/brainstormforce/astra/blob/8b2207141fcd78d9c90bc15d33cf6325fd77dba9/inc/customizer/class-astra-fonts.php#L172](https://github.com/brainstormforce/astra/blob/8b2207141fcd78d9c90bc15d33cf6325fd77dba9/inc/customizer/class-astra-fonts.php#L172)
 * Customized it to ‘swap’ from ‘fallback’ and uploaded to server, works absolutely
   fine. Thank you once more for this amazing theme, god bless.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Optimize Google Font’ is closed to new replies.

 * ![](https://i0.wp.com/themes.svn.wordpress.org/astra/4.12.6/screenshot.jpg)
 * Astra
 * [Support Threads](https://wordpress.org/support/theme/astra/)
 * [Active Topics](https://wordpress.org/support/theme/astra/active/)
 * [Unresolved Topics](https://wordpress.org/support/theme/astra/unresolved/)
 * [Reviews](https://wordpress.org/support/theme/astra/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [andcha](https://wordpress.org/support/users/andcha/)
 * Last activity: [6 years, 10 months ago](https://wordpress.org/support/topic/optimize-google-font/#post-11607633)
 * Status: resolved