The <link>
element
Gives the URI of some other resource that's either needed by this document (such as a CSS stylesheet) or that is related somehow (such as the next document in a sequence).
This is an empty element, so it shouldn't have a closing tag.
Full list of attributes
All the usual HTML global attributes are available
crossorigin
- A CORS settings attribute for files to be downloaded from third party sites.
href
- The URI of the resource that's being linked to.
hreflang
- Language tag for the natural language used in the linked resource.
media
- A media query which specifies which kinds of media or devices the linked file should be used for. Use mainly for linking to different stylesheets for screen and print styling. Defaults to
all
. rel
- Indicates the relationship between this document and whatever is at the URI given by
href
(for examplestylesheet
ornext
). sizes
- Gives the sizes of icons in an icon file, such as
32x32
. Should only be used withrel=icon
. title
- Has a special meaning only with
rel=stylesheet
, in which case it contains an alternative style sheet set, as defined by the CSS Object Model specification. type
- The MIME type (that is, file format) of the resource being linked to.