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 trialKunika Sood
4,472 PointsWhy am i getting a bummer- 'Be sure to include sans-serif as a fallback'?
What is wrong with the below code?
h1{
font-family: 'Source Sans Pro', 'Roboto Condensed', sans-serif;
font-size: 1.75em;
font-weight: normal;
line-height: 0.75em;
}
3 Answers
Jacob Miller
12,466 PointsI think the code challenge is looking for ONLY a sans-serif fallback, not a second font and then the sans-serif. If you remove one of your fonts it should work.
Shivam Sadachar
8,109 PointsI don't think the problem is lies in your code - your code looks great. But, the Code Challenge asked you to only link one Google Font to your HTML, and then it expects you to add only one google font to your stylesheet.( Instead, you linked 2 fonts to your html and added 2 google fonts to your CSS.)
So the code engine expected the first font in the 'font-family' property to be whatever font you specified and the second font to be 'sans-serif'. Since you added two fonts and then sans-serif, the code engine didn't recognize that and it marked you wrong.
Kunika Sood
4,472 PointsThanks Jacob and Shivam, it worked.