- This topic is empty.
- The forum ‘CSS’ is closed to new topics and replies.
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:
Is there a better way of doing this within the properties of CSS Grids?
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.
yeah margin:0 auto; is going to be the most elegant solution… unless you want content in the other two columns eventually?