MyBB Internal: One or more warnings occured. Please contact your administrator for assistance.
WebPagetest Forums - preload font

WebPagetest Forums

Full Version: preload font
You're currently viewing a stripped down version of our content. View the full version with proper formatting.

I order to improve my perf i decide to preload my font.
<link rel="preload" href="" as="font" type="font/woff2" media="screen and (min-width: 624px)"

But in consol I got the following message
The resource was preloaded using link preload but not used within a few seconds from the window's load event. Please make sure it has an appropriate `as` value and it is preloaded intentionally.

But this font is used? So, is there anyone who can explain me my mistake?
Add the crossorigin attribute i.e.

<link rel="preload" href="" as="font" type="font/woff2" crossorigin>

Thanks for you help, but this doesn't change anything and I'm not surprise as i load font from my own domain.
Do you have a link to the page in question?
Thanks a lot I sent you by PM
This might be something you've already done, but try disabling the media query (to simplify testing as much as possible) and double check the font you're loading is being downloaded by the current page in the network tab. Document/CSS parsers in browsers will speculate whether they should load a web font by examining the text content on a page and the styles applied to it.
Reference URL's