The difference between <html>
and <body>
is easy to overlook. When applying global styling to a webpage I tend stack up all the CSS rules to the <body>
element without even thinking much. This is not incorrect but as a frontend developer it is a good idea to be aware of every lines of codes we wrote. In this CSS-Tricks article, Geoff Graham goes over the key differences between the use of <html>
and <body>
in CSS and consider some practical applications where styling one over the other might make sense. Hit the button to learn more.
comment 0