Curiosity
Do browsers fetch and download all the files specified in @font-face
declarations or do they grab only the ones referenced in stylesheets?
For Instance
Imagine I have these 3 @font-face
declarations:
@font-face {
font-family: 'A';
src: url('http://fonts.com/font-a.woff2') format('woff2');
}
@font-face {
font-family: 'B';
src: url('http://fonts.com/font-b.woff2') format('woff2');
}
@font-face {
font-family: 'C';
src: url('http://fonts.com/font-c.woff2') format('woff2');
}
And then my styles are as follows:
body {
font-family: 'A';
}
h1 {
font-family: 'B';
}
Does the browser fetch font C
, even though it is not referenced in the stylesheet? Is there a definitive answer within the specification?