如何为Framer Motion中的退出属性实现不同类型的过渡?
<motion.div
initial={{opacity: 0, transform: 'scale(0.5)'}}
animate={{opacity: 1, transform: 'scale(1)'}}
exit={{opacity: 0, transform: 'scale(0.5)'}}
/* I want "type" to be different only for the exit animation */
transition={{ type: "spring", stiffness: 200 }}
></motion.div>
我希望将“弹簧”过渡用于initialand animate,但对于退出我想要不同的类型。退出动画正在工作(我正在使用<AnimatePresence>包装器,但我只是想要一个不同的退出行为。