(I am posting this here because I couldn't find a solution and eventually figured it out through trial and error. Hopefully, this information can help others with the same question.)
Note: This is not the same as the discussion on Single-line vs multi-line CSS formatting, which focuses on whether each property should be on its own line or all properties for a selector should be on one line. My query was about incorporating line breaks within a property's value.
If you have a lengthy value for a CSS property (such as an extensive list of fallback fonts for the font-family
property), is it possible to format that list neatly with line breaks, or will it cause issues?
For example, if you have
body {
font-family: fontA, fontB, fontC, fontD, fontE, fontF, fontG, ..., fontZ;
}
Can you structure it like this?
body {
font-family: fontA,
fontB,
fontC,
...,
fontZ;
}
?