I'm creating offcanvas navigation menu on mobile view and I have encountered a problem where there is like 0.3s delay before adding class .show.
I tried adding custom class .active via jquery but results are the same - even tho that class is added without delay, transition on this class is still delayed.
.collapse.active{
transform: translateX(0%);
}
That's most likely caused by adding and calculating inline style height that I don't really need as i alyways want nav to be 100vh. Is there a way to cut or speed up the calculating part?
Tried adding this code but doesn't help at all.
.collapsing {
-webkit-transition: all 0s ease-out;
-o-transition: all 0s ease-out;
transition: all 0s ease-out;
height:0 !important;
display: none;
}
Bootply link (with delay): https://www.bootply.com/9dFOT7Q2Ct
I did same thing on codepen and there it works just fine - It doesnt even add inline style to #navbarNav so maybe a jquery issue (I'm using recommended jquery-3.2.1)
Codepen link (without delay for some reason): https://codepen.io/janheder/pen/rGLJLb