Unstyled Text

  • Hi guys,

    I’m wondering if there’s CSS code I can add to my blog that would eliminate the “flash of unstyled text” I see every time I load my site (there’s a lag using every browser I know of, sometimes quite large, between when the page loads and when the header and blog text “snaps” from the default style to my custom style).

    Until now it’s something I just decided to live with but after doing some research, it seems it’s a common problem that may have a solution.

    Thanks in advance for your help!

    The blog I need help with is: (visible only to logged in users)

  • This is something we are aware of, and it is sort of happens anytime a theme is using web-based fonts served from an outside source. There are two ways to handle this sort of thing.

    One is to wait until the web font is served and loaded before allowing the site to start loading for a visitor. The issue with this is that, if the font servers are perhaps heavily loaded, or if the internet itself between the font servers and our servers is heavily loaded, it can mean that the delay in the site starting to load will be too long, and people may think there is an issue and click away and not visit the site.

    The second way is to go ahead and allow the site to start loading so that there isn’t the delay for the visitor and then pop in the fonts when they are loaded to our servers.

    It was decided after much consideration and testing that the second option was preferable to the first at this time. This is all very much still on our minds and something that we want to find a reliable solution for, but at this time what we have is the best compromise solution available.

  • Ok, thanks! So basically it’s something that I may just not see anymore at some point in the future. Until then, is there a way to use different fonts with my theme that this doesn’t happen with? Or are my options basically to use the default font for the theme or else deal with the lag in font loading?

    Thanks again

  • So basically it’s something that I may just not see anymore at some point in the future.

    That is certainly our desire. It is definitely something we wish to resolve.

    Some of our themes use web fonts by default, but Origin uses fonts that are installed on virtually all computers, so switching back to the default fonts would take the delay away.

  • Thanks!

    Do you know if self hosted sites using WordPress.org run into this same problem as well? I’ve been considering migrating for awhile anyway and this could help my decision along…

    Thanks again :)

  • You know, it all depends on the theme you end up choosing. Some will hold and wait for the web fonts to load, no matter how long that takes. On one site I did for a friend, I’ve noticed that at times it may be 5 seconds or longer before the site starts to load (which to me is waaaayyyyy too long). If I disable the web fonts, then the site begins loading in milliseconds.

    Anytime you rely on pulling fonts or other things from different servers than your site is hosted on, you can run into these issues. The web font servers and sites work hard to keep this delay as short as possible, but there are tons of things that can cause these delays.

    The short answer is, this is a web-wide issue, not just something here at WordPress.com. We chose what we consider the best option. With the short (and getting shorter) attention span/tolerance of web users, our choice was to give the visitors something to see so that they didn’t click away thinking the site was down or something.

  • The topic ‘Unstyled Text’ is closed to new replies.