Skip to main content

Forums

This topic contains 2 replies, has 3 voices, and was last updated by  bearhead 1 year, 11 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #260540

    nieternst
    Participant

    The only way I found to max-width a column and keeping it centered was using max-width and margin: 0 auto; on the container.

    See my codepen for an example:
    https://codepen.io/evm/pen/RLKgQZ

    Is there a better way of doing this within the properties of CSS Grids?

    #260545

    Paulie_D
    Moderator

    Your current solution is the simplest.

    I’m not sure why you would want to complicate it by using CSS Grid unless there is a specific layout you are trying to achieve.

    #260635

    bearhead
    Participant

    yeah margin:0 auto; is going to be the most elegant solution… unless you want content in the other two columns eventually?

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.

icon-link icon-logo-star icon-search icon-star