Disabling animation
Closed this issue · 2 comments
santaclauze commented
You're collpase is working neatly, but tI am working on a project that requires me to toggle the animation on and off. I do want to have the functionality to work but without the animation.
Do we have access to a props to do enable/disable animation?
nkbt commented
Just replace Collapse with div
or something, that should do.
render() {
const {isAnimated, children} = this.props;
return isAnimated ?
<Collapse>{children}</Collapse> :
<div>{children}</div>
}
santaclauze commented
Yeap, I worked around your proposition and created an HoC so that I cold target it with my own settings. Only hicup, is that you have to wrap the content with another div which just isn't as beautiful. But it works!