How can i align two divs on a horizontal line in a way that it is resized to one column when the user resize the browser? | Sololearn: Learn to code for FREE!
Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок
+ 1

How can i align two divs on a horizontal line in a way that it is resized to one column when the user resize the browser?

I want to make it flexible on various displays e.g mobile, table desktop, laptops etc

8th Apr 2018, 12:24 PM
Fotie
Fotie - avatar
1 ответ
+ 2
div { width: 50%; display: inline-block; } @media (max-width: 768px) { div { width: 100%; } }
8th Apr 2018, 12:29 PM
Toni Isotalo
Toni Isotalo - avatar