Answer the question
In order to leave comments, you need to log in
Bootstrap+Flexbox: Centering middle element?
Hello!
Essence of the question: I'm typesetting on Bootstrap 4.3, and a task arose.
There are conditionally three blocks in the header: left, central (logo, for example) and right, which are currently aligned according to the rule .justify-content-between
, the essence of which is shown in the picture below.
If you add content to the right block, then its width increases, and therefore shifts the central element to the left. Is there any standard pretty solution that allows the left box to stick to the left, the right box to the right, and the center box to be centered relative to the parent element, regardless of the width of any of the three boxes?
Thank you all in advance! :)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question