I am reading a CSS Wizardry article on web optimization. http://csswizardry.com/2013/01/front-end-performance-for-web-designers-and-front-end-developers/
This is a great article. I invite everyone to read it.
The article suggests that CSS be in a critical way and should not be served across resource domains. This is because serving through an additional domain will result in a DNS lookup that takes time. Critical path = time between page request and actual observation.
Best practice dictates that you should characterize many assets by subdomains, but not CSS.
However, when I browse the source code of a large website such as Facebook or Apple, do they serve their CSS from a subdomain? Why are they doing this?
<link rel="stylesheet" href="http://static.ak.fbcdn.net/rsrc.php/v2/yz/r/Hwq5_AIg0hW.css" /> <link rel="stylesheet" href="http://static.ak.fbcdn.net/rsrc.php/v2/y-/r/UgmvVXsZ1MP.css" /> <link rel="stylesheet" href="http://static.ak.fbcdn.net/rsrc.php/v2/yY/r/uHqkbF3y3Er.css" /> <link rel="stylesheet" href="http://images.apple.com/global/styles/base.css" type="text/css" /> <link rel="stylesheet" href="http://images.apple.com/v/home/p/styles/home.css" type="text/css" /> <link rel="stylesheet" href="http://images.apple.com/v/home/p/styles/billboard.css" type="text/css" /> <link rel="stylesheet" href="http://images.apple.com/home/styles/home.css" type="text/css" />
source share