flex: 1 and flex: 1 1 auto are not interchangeable when the parent has no definite height

작성자

카테고리:

← 피드로
r/programming · /u/HolidayChard9706 · 2026-08-20 개발(SW)

Short version, so you do not have to click: flex: 1 expands to flex: 1 1 0%. That 0% is a percentage basis and resolves against the parent's height. A panel that is height: auto under a max-height cap has no definite height, so the…

원문 보기 ↗