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

CSS CSS Grid Layout Flexible Sized Grids Repeat Tracks with auto-fill and auto-fit

Question regarding Repeat Tracks with auto-fill and auto-fit

At 07:06, is it possible to make the 'no. 8' div to expand and fill up the remaining gap?

1 Answer

Steven Parker
Steven Parker
231,248 Points

Yes, that can be done. In the next stage of this course, you'll learn some additional properties that allow you to span columns using the grid lines as a reference.

Noted! Thanks.

I understand that auto-fit is supposed to fit all the explicit columns into the remaining space. if that's the case how come div no.8 is not expanded to fit the remaining space at 07:06?

Steven Parker
Steven Parker
231,248 Points

The "auto-fit" setting will expand columns to fit the available space, but it will not cause items to cross grid lines.

Noted. Thanks for the explanation!