DEV Community

Discussion on: How does @import works in CSS? What is the pros and cons. 🤔

Collapse
 
fyrfli profile image
Camille

Was wondering about this - especially if all you’re importing is fonts. I use the @import with Google fonts quite a bit. Other stylesheets I use the html links for.

What’s the consensus on the @import usage in this case?

Collapse
 
acode123 profile image
acode123

It really depends, the @import statement does harm SEO a tiny bit, because it increases the load time. I would reccomend using the HTML link tag, but it's your choice!