A developer wants to create a text container that breaks into three columns on wide screens but remains a single column on small devices. Which CSS property combination should be used to achieve this responsive multi-column layout?

  • column-count: 3; column-width: auto;
  • columns: 3 auto;
  • flex: 1 0 33%;
  • grid-template-columns: repeat(3, 1fr);
To achieve a responsive multi-column layout, using the grid-template-columns property with repeat ensures three columns on wide screens while maintaining a single column on small devices.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *