Which method is best for importing multiple stylesheets? Is one method more efficient than the other?
I once read this article about performances and <link>
vs @import
: don’t use @import ; quoting a small portion of it :
use LINK instead of @import if you want stylesheets to download in parallel resulting in a faster page.
It's quite recent (April 2009), so should still be mostly true -- and written by Steve Souders, whose name is quite well-known when it comes to front-end performances.
On a more subjective point, I quite prefer using several <link>
from my main HTML file : this way, I am able to see in only a quick glance what css files are called -- either looking at the template file on the server, or looking at the generated HTML source on the client side.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With