[css-fonts] Specify generic()
versions of existing generic font families
#10608
Labels
generic()
versions of existing generic font families
#10608
Re: https://drafts.csswg.org/css-fonts/#generic-family-name-syntax
It appears we introduced a
generic()
syntax for new generic font families, but existing generic font families are still only specifiable using keywords.Specifying them using
generic()
as well is not only more consistent and more readable, but it would also facilitate feature detection via@supports
— which is currently impossible (this post recommends a JS method, but it doesn’t actually work).Precedent: when we switched to a double colon for future pseudo-elements, we supported both syntaxes for existing pseudo-elements so that authors could eventually move towards that as a convention for all pseudo-elements. It’s the same here: we want authors to eventually move towards
generic()
for all generic font families.The text was updated successfully, but these errors were encountered: