0
votes

So I decided to start optimizing my site and fixing things, and this came up in the W3C Validator.

Value Error : font-family "Neue" is not a font-family value : "Montserrat",Helvetica "Neue",Helvetica,Arial,sans-serif

Value Error : font-family 'Neue' is not a font-family value : Helvetica 'Neue',Helvetica,Arial,sans-serif

Now, I declared my font families as follows:

font-family: "Montserrat",Helvetica "Neue",Helvetica,Arial,sans-serif;
font-family: Helvetica 'Neue',Helvetica,Arial,sans-serif

The difference between the two being the usage of double quotes and single quotes " vs ' And using a Google web font in the first one being "Monteserrat"

How can I fix this and make it validate?

1

1 Answers

2
votes

Each family needs to be all in quotes, or not at all. So you can say:

font-family: "Helvetica Neue",Helvetica,Arial,sans-serif

or:

font-family: Helvetica Neue,Helvetica,Arial,sans-serif

However, you shouldn't just quote the Neue part. See https://developer.mozilla.org/en-US/docs/Web/CSS/font-family