Multi-column Layout

suggest change

CSS Multi-column Layout flows one element's content through multiple columns:

.article {
  columns: 18rem 3;
  column-gap: 2rem;
  column-rule: 1px solid color-mix(in srgb, currentColor 25%, transparent);
}

.article h2 {
  break-after: avoid;
}

.article figure {
  break-inside: avoid;
}

The columns shorthand combines a preferred column-width and maximum column-count. The browser chooses a count that fits the available space.

Multi-column layout is suited to continuous prose. It is generally a poor choice for interface cards because content flows vertically down one column and then into the next, which can make scanning and keyboard navigation confusing. Use Grid for independently ordered items.

Modern browsers support the multi-column properties without vendor prefixes.

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents