Add javascript event listeners for CSS animations and transitions.
Useful for transitioning elements between display block and none.
Plugin works through normal HTML include or through NPM
<script src="/pathto/transition.js"></script>
var Transition = require('/pathto/transition.js');
Transition.trigger({
el: element, // DOM element
classes: ['transition-type-start', 'transition-type-end']
});
Transition.trigger({
el: element, // DOM element
animationEl: subElement, // Another DOM element
classes: ['transition-type-start', 'transition-type-end'],
callback: function() {
// run callback
}
});
Found in examples/transition.html