How Enter/Exit animations work
mainThe library uses a combination of base classes and transform/parameter classes to create animations.
To trigger an animation, you must apply a base class to define the animation type (in for entrance or out for exit), and then combine it with transform classes to define the visual effect.
Core Concepts:
<io>: The animation type. Useinfor entrance oroutfor exit.<dir>: The direction for sliding.- For entrance:
in-from-top,in-from-bottom,in-from-left,in-from-right,in-from-start,in-from-end. - For exit:
out-to-top,out-to-bottom,out-to-left,out-to-right,out-to-start,out-to-end.
- For entrance:
*: A value (like a percentage or number) to customize the effect.
Example:
<div class="animate-in fade-in zoom-in">...</div>