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 trialDavide Pupparo
8,452 PointsDisplay: inline-block or float: left?
Hi there! Why is Nick using display: inline block on the navigation items instead of floating them to the left? What are the advantages of one technique over the other? I'm guessing the fact that giving display:inline-block doesn't force us to re-set a width for the li elements... Am I right? sorry for my english ^___O
3 Answers
Noel Gonzalez
Full Stack JavaScript Techdegree Student 5,130 PointsI have always wonder the same thing. I have the habit of floating my divs left.
Davide Pupparo
8,452 PointsMe too. Altough Nic's solution seems to be a good alternative. I'm just wondering about what could be the cons of that approach
Davide Pupparo
8,452 PointsDavide Pupparo
8,452 PointsThans a lot Kazimiers!