-
AuthorPosts
-
December 2, 2024 at 11:51 am #1472696
Hello!
I am crazy about the page speed optimisation.
I use fast CDN.
Is it possible in this theme to get the google fonts locally, cache it to my cdn and load all fonts as one http request (as we do with scripts and css)?Thank you!
December 3, 2024 at 5:24 am #1472757Hey ibuzaev,
Thank you for the inquiry.
You can upload Google Fonts using the Custom Font Manager and load them locally, but we’re not sure if they will be compatible with your CDN. If this is not possible, you may need to rely on third-party plugins to load the fonts. Please check the link below for more info.
// https://kriesi.at/documentation/enfold/typography/#how-to-upload-custom-fonts
Best regards,
IsmaelDecember 3, 2024 at 7:04 am #1472758why not loading directly from your CDN Servers : you can try the option : Enfold – Performance – Show advanced Options ( switch on ) – Custom Font Loading Source : “Load from CDN Server”
Starting with 5.4 you can decide to load your custom fonts from a CDN server. In this case you must include your own @font-face rules in head. Enfold will supress output of default @font-face rules in dynamic_avia css file to avoid double loading.
December 3, 2024 at 7:29 pm #1472809Thank you, Guenni,
Will it work with google fonts too (which are not hosted on my server now)?December 4, 2024 at 10:02 am #1472866Hi,
Will it work with google fonts too
Yes, you can download the Google font and then add the @font-face rule to manually load it.
Example:
@font-face { font-family: 'Open Sans'; src: url('https://cdn.example.com/fonts/OpenSans-Regular.woff2') format('woff2'), url('https://cdn.example.com/fonts/OpenSans-Regular.woff') format('woff'); font-weight: 400; /* Regular */ font-style: normal; } @font-face { font-family: 'Open Sans'; src: url('https://cdn.example.com/fonts/OpenSans-Bold.woff2') format('woff2'), url('https://cdn.example.com/fonts/OpenSans-Bold.woff') format('woff'); font-weight: 700; /* Bold */ font-style: normal; }
Best regards,
IsmaelDecember 5, 2024 at 3:56 pm #1473018Thank you, Ismael!
-
AuthorPosts
- The topic ‘Google Fonts Locally’ is closed to new replies.