I am using nested Collapsibles in a structure like this:
FlatList ---> Collapsible in each item ---> FlatList in each Collapsible ---> Collapsible in each item.
On IOS this is working fine, however on Android I get the following error when trying to expand the inner Collapsible:

It appears that for some reason, one of the Collapsibles (the outer one would be my guess) is getting "NaN" for height property which leads to a crash.
I managed to fix this by adding the following check to Collapsible.js (line 150):
this._animation = Animated.timing(this.state.height, {
toValue: height ? height : 0, // <------ Here
duration,
easing,
}).start(() => {
if (this.unmounted) {
return;
}
this.setState({ animating: false }, () => {
if (this.unmounted) {
return;
}
this.props.onAnimationEnd();
});
});
It seems like a bug to me, you might be able to reproduce this.
react: 16.8.3
react-native: 0.59.10
react-native-collapsible: 1.5.0
created a PR for this, hope it get merged
I hope this gets merge soon too, in the meantime I just forked your fork :)
Most helpful comment
created a PR for this, hope it get merged