Wait for fonts to load before rendering web page

后端 未结 11 1368
终归单人心
终归单人心 2020-11-27 15:38

I\'m using @font-face to embed fonts in my website. First the text renders as the system default, and then (once the font file has loaded presumably) the correct font render

11条回答
  •  悲哀的现实
    2020-11-27 16:10

    Maybe something like this:

    $("body").html("");
    

    Then when the page loads, replace body's content with the actual content and hopefully, fully rendered fonts, you may have to play around with this though...

提交回复
热议问题