In Bootstrap 3, which class would you use to create a responsive column that stacks on mobile devices?

Prepare for the Web Development 201 Test with flashcards and multiple choice questions including hints and detailed explanations. Boost your exam readiness today!

In Bootstrap 3, the class used to create a responsive column that stacks on mobile devices is "col-xs-". This class is specifically designed for extra small devices, which typically refers to mobile devices. When you use this class in your grid system, the columns will stack vertically on screens that are smaller than the "sm" breakpoint (i.e., smaller than 768 pixels).

The "col-xs-" class allows you to define how many columns an element should occupy in the grid when viewed on mobile devices. For example, using "col-xs-6" will make an element take up half of the width on mobile screens, while on larger screens you can specify additional classes (like "col-sm-" or "col-md-") to determine how the layout changes as the screen size increases.

In contrast, the other breakpoint classes, such as "col-sm-", "col-md-", and "col-lg-", are designed for small, medium, and large devices, respectively. These classes only take effect when the viewport is larger than the defined breakpoints, which means they do not govern the stacking behavior on mobile devices. Therefore, "col-xs-" is the correct choice for ensuring that columns appropriately stack on mobile screens.

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy