require-font-weight
Require explicit font-weight in every @font-face block.
Rule catalog ID: R003
Targeted pattern scopeโ
font-weightdeclarations inside@font-face.
What this rule reportsโ
@font-faceblocks that omitfont-weight.
Why this rule existsโ
Missing weights create ambiguous mapping and make variable/static face upgrades riskier.
โ Incorrectโ
@font-face {
font-family: "Inter";
font-style: normal;
src: url("./inter.woff2") format("woff2");
}
โ Correctโ
@font-face {
font-family: "Inter";
font-style: normal;
font-weight: 400;
src: url("./inter.woff2") format("woff2");
}