Recall & Review
beginner
What is Flexbox in web design?
Flexbox is a layout method that helps arrange items in a container, making it easy to align and distribute space among them, even when their size is unknown or dynamic.
Click to reveal answer
beginner
Why is Flexbox better than using floats for layout?
Flexbox simplifies layout by automatically adjusting item sizes and positions without needing hacks like clearing floats. It handles alignment and spacing more naturally and responsively.
Click to reveal answer
intermediate
How does Flexbox help with responsive design?
Flexbox allows items to grow, shrink, or wrap based on the screen size, making it easy to create layouts that adapt smoothly to different devices without extra code.
Click to reveal answer
beginner
What Tailwind CSS class enables Flexbox on a container?The class
flex activates Flexbox on a container, allowing you to use other flex utilities to control layout and alignment.Click to reveal answer
intermediate
Name two common Flexbox properties to align items.
Two common properties are
justify-content (controls horizontal alignment) and align-items (controls vertical alignment). In Tailwind, these correspond to classes like justify-center and items-center.Click to reveal answer
Which Tailwind class activates Flexbox on a container?
✗ Incorrect
The
flex class in Tailwind applies display:flex to the container, enabling Flexbox layout.What does Flexbox help you do easily?
✗ Incorrect
Flexbox is designed to align items and distribute space inside a container efficiently.
Which property controls vertical alignment in Flexbox?
✗ Incorrect
align-items controls vertical alignment of flex items within the container.Why is Flexbox preferred over floats for layout?
✗ Incorrect
Flexbox simplifies layout by automatically managing alignment and spacing without hacks.
How does Flexbox help with responsive design?
✗ Incorrect
Flexbox lets items adjust their size and position to fit different screen sizes smoothly.
Explain in your own words why Flexbox is essential for modern web layouts.
Think about how websites look good on phones and computers without complicated code.
You got /4 concepts.
Describe how you would use Tailwind classes to center items horizontally and vertically using Flexbox.
Remember the classes that control horizontal and vertical alignment.
You got /4 concepts.