Flexbox problem : Can't Resize child elements | Sololearn: Learn to code for FREE!


Flexbox problem : Can't Resize child elements

Code link: https://code.sololearn.com/WLE931y38s1r/?ref=app I have set child element width to 100vw but it's not occupying all given size(i.e 100vw) flexbox is dividing it's entire width into 4 parts for 4 children. I wanted each child div to have full screen width and then apply overflow-x:scroll; but I failed to resize child elements. also note that I want all child divs to be horizontally placed one after another. not vertically. In case of flex-direction:column; every element will have desired size but I want divs horizontally placed How to fix this.

1/4/2020 4:46:11 PM


3 Answers

New Answer


Change width of div to 'min-width:100vw;' This will make sure the size of element dont get small. //also, flex element will be of same width make it overflow-x : scroll; to cover edit:: Code - https://code.sololearn.com/WuPRQKWHk35J/?ref=app


Jaydeep Khatri , thanks bhai.


Your welcome 🇮🇳Omkar🕉 😊