Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS CSS Basics (2014) The Box Model Margins

font stacks:

i noticed that when doing font stacks, even if I don't put a default fallback font...the browser still displays text if the imported fonts aren't compatible. why than are we supposed to include a default fallback font?

1 Answer

Hey John,

The reason why we use a font stack with a default font is to keep the typeface inline with what is happening on the page. If we don't specify a fallback font to be used, the browser will default to whatever font it wishes. Perhaps you have some cool effects going on with a serif font, but the imported fonts don't show up (and there's no fallback) so the browser decides to display the fonts with a sans serif font. Your effects would be off and wouldn't look right. And that's just one case. At least with a fallback font, your typeface will be inline with the typeface of the imported fonts.