Search code examples
cssinternet-explorer-11css-grid

Setting min-height in grid container in IE11


I'm trying to set

display: -ms-grid;
min-height:##px;
height:auto;

It seems IE doesn't support min-height in CSS Grid.

Is there any alternative way for achieving the same thing?

Thanks in advance. ❤️


Solution

  • It seems that IE has a min-height bug when using CSS Grid. We can use css-tricks to fix it in IE. You could give the parent a grid column container like below:

    display: -ms-grid;
    -ms-grid-columns: 100%;
    

    Then the min-height property will work in IE.