I am using ToggleClass to trigger an animation from css and need to call a function after the animation has ended. I'm calling a function from the typed.js library.
$('.anim').toggleClass('slide-down');
$(".sentence").typed({
strings: ["first sentence", "Second sentence." ],
typeSpeed: 45,
backDelay: 500,
callback: function(){}
});
how can I make the typed function wait till the toggleClass has finished?