oblador / react-native-collapsible

Animated collapsible component for React Native, good for accordions, toggles etc
MIT License
2.43k stars 455 forks source link

is collapsible suppose to support basic slide in/out animation? #423

Closed kimkong88 closed 2 years ago

kimkong88 commented 2 years ago

I'd assume so by looking at its props..

` <Collapsible collapsed={!this.props.selected} duration={5000} onAnimationEnd={() => console.log("animation ended")}

{item.description}

`

it simply hide/show child element without animating, onAnimationEnd is not fired.

I am using Expo v 42 which uses react native v0.63. Can anyone verify if it's suppose to support basic animation?

kimkong88 commented 2 years ago

note: defining easing did not work either. note: it's probably me using collapsible in flatlist and I am passing selected prop from outside, so probably it re renders entire flatlist everytime prop changes. I figured componentDidUpdate in Collapsible did not get triggered when I changed the prop value. note: it was actually wrong key prop passed into renderItem. solved!