as for react with react-spring hiding to make an animation for a div when click on button {aa}?
https://codesandbox.io/s/silly-feistel-j1snp
const props = useSpring({config: { duration: 1250 },opacity: 1, from: {opacity: 0}});
const foo =() =>{
setAa(!aa)
}
return (
<div className="App">
<div onClick={()=>foo()}>aa</div>
<br/>
{aa &&
<animated.div style={props}>I will fade in</animated.div>}
</div>````