How to Import Style Sheets with @import in CSS
@import rule in CSS is used to import one style sheet into another.
The following two syntaxes can be used to import style sheets using
@import in CSS:
@import "styles.css" mediatypes;
@import url("styles.css") mediatypes;
In these examples, mediatypes would be replaced by a comma-delimited list of media types (
speech) to which the imported style sheet applies.
In general, we recommend avoiding using
@import to import one stylesheet into another because it forces multiple concurrent downloads of separate files (the various CSS stylesheets) and thus can slow down the loading of the page. It is important for you to know that the
@import statement exists and how it works.
Author: Chris Minnick