5 ms·
> Problem is that flexbox ruins CSS box model that mandates that width CSS property is what defines the width of inner box of the element. Now they have flex-ba
by et-al 9y ago
> Problem is that flexbox ruins CSS box model that mandates that width CSS property is what defines the width of inner box of the element. Now they have flex-basis that if defined in galaxy far, far away overrides that width by something else.
I'm not quite following; may you please explain this? Thanks.
- c-smile 9y agoHaving this CSS: .flex-container { border: 1px solid #555; display : flex; } .flex-container > span { display:block; border: 1px solid #900; flex:1; width:100px; } and this markup: <div class="flex-container"> <span>Foo</span> <span>Bar</span> </div> what would be the width of each <span> there?