How does Bootstrap transition the height back and forth?

Bootstrap simply adds the .collapsing class, and do some cleanups after every transition and it somehow works. Here is a Bootstrap navbar demo. The viewport must be below 1400px for the toggle to appear. https://codepen.io/noobcoder137/pen/KKbpEzx?editors=1100 pay attention to the classes in div.navbar-collapse. here is my demo: https://codepen.io/noobcoder137/pen/XJreXqx?editors=0011 I can make the transition work when opening with the help of force reflow, but the transition doesn't work when closing. I know i can transition height with grid-row and so. I am just curious about the bootstrap approach.
0 Replies
No replies yetBe the first to reply to this messageJoin

Did you find this page helpful?