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
Owa Aquino
19,277 Pointsa flex-wrap question
Hi guys!
Just a quick question here. I'm creating a 3 column layout with flex-box, where when it comes to a specific resolution the third column should go bellow the 1st and 2nd column like the Guil Hernandez makes in his course.
So here is the mystery: when I apply the css below it doesn't work
@media (min-width: 769px) {
.row{
display: flex;
flex-wrap: wrap;
}
.col {
flex: 1 50%;
}
}
but if apply this (code below) instead it works.
@media (min-width: 769px) {
.row{
display: flex;
}
.col {
flex: 1 50%;
}
.row {
flex-wrap: wrap;
}
}
It's kinda vague to me.. Hope you guys can help. TYIA!
Owa Aquino
19,277 PointsHi Steven Parker !
Here is a snapshot of my workspace.
Thank you for helping me solving the mystery.. :D
1 Answer
Steven Parker
243,318 PointsOn my browser, they do work the same.
But I noticed one thing that might possibly be an issue on a different browser: in your first .row rule, there's no space between the class name and the open brace.
Try adding the space and see if makes both forms work for you also.
Steven Parker
243,318 PointsSteven Parker
243,318 PointsThis doesn't make sense, those should operate identically.
Could you make a snapshot of your workspace and post the link to it here?