Browser & Web Performance · Middle · Question 32 of 75

Why must a preloaded font have the crossorigin attribute?

<link rel="preload" href="/fonts/inter.woff2" as="font" type="font/woff2" crossorigin>

Explanation

This is needed even for same-origin fonts. A mismatch shows up as an 'unused preload' warning in the console.

Further reading

Problem with a question

Browser & Web Performance · Middle · question 32

Test yourself

Take the Browser & Web Performance · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz