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


Rhonda Bradley
Rhonda Bradley
2,010 Points

How does h1 affect h2 and body fonts?

So we changed the font of h1 to the new google font, but I'm unclear as to why we need to tweak it so that h2 and body don't take on those values?

Since the rule says h1 {blah blah blah}, why would it affect h2 or body?

Am I understanding this wrong? It brings up a multitude of questions about cascading rules. Thanks for any guidance you can give on this :)

1 Answer

Greg Kaleka
Greg Kaleka
39,021 Points

Hi Ronda,

It looks to me like you're thinking about this right. Without seeing the actual code used to implement the font, it's hard to say, but if the rule is truly targeting only h1, and that's the only place you're implementing the font, I don't think it should affect h2 or body at all.