Simple reusable jQuery function for toggling visibility of a div with CSS animation.
Script is animating max-height CSS property value of target element.
Usage
$('[data-toggle]').toggler();
Required Markup
Required CSS
jQuery Function
CodePen Demo
See the Pen Simple reusable jQuery Toggler by Vlado (@bobz-zg) on CodePen.
Well that saved me a headache… very helpful. Thanks Vlado!
Awesome stuff Vlado! This Script works wonders. Thank you.