Using CSS Flex-Grow and Flex-Shrink together?

Hi All–

Long time lurker and first post. I love what is happening with the updates so I am back to working through them and promised myself to get more involved! (Thanks in advance for your kindness…)

I am working through the CSS Flexbox challenges and am in the flex-grow and flex-shrink section.

I was using the ide and it seems that you cannot use them in tandem?

With flex properties, if they are placed in separate classes or ids, and not on the same object/div–can they be used together?

Or is it a case where it is one choice of flex attribute for the entire project?

Thanks again for everyone being here–look forward to learning with you!


No, you just apply whatever you want to any element that is a child of any element with display: flex. flex-grow, flex-shrink and flex-basis are, respectively, you saying “I want to allow this element to grow to this maximum, allow it to shrink to this minimum, and the size it starts at be ___”.