Animation of Radix Primitives can generally be summed in terms of the
exiting phases of a stateful component. In either case, adding animation to a Primitives component should feel similar to any other component, but there are some caveats noted here in regards to
exiting animations with JS animation libraries.
The simplest way to animate Primitives is with CSS. You can use either
animation and it should work with
exiting animations as expected.
forceMount prop on many components to allow consumers to delegate the mounting and unmounting of children based on the animation state determined by those libraries.
For example, if you want to use React Spring to animate a
Dialog, you would do so by conditionally rendering its
Content parts based on the animation state from a hook like