简体   繁体   中英

Loading CSS too slow using Javascript

I'm developing a online registration system. I have my CSS files loaded in javascript file using "skel.init". When loading other pages or refreshing the website. It loads CSS pretty slow that my website will appear with no css for almost 1 sec while loading. Are there any solutions that can fix this? (PS It's not my network's problem. I had my network tested)

如果通过页面<head>中的<link>加载CSS,浏览器将在页面HTML内容之前加载CSS,并且如果未应用正确的CSS,您将看不到该站点。

I know the problem... This is called the Flash of Unstyled Content. I solve this on Eliminate flash of unstyled content

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM