Reputation: 153
I'm using ReactCSSTransitionGroup from here: https://facebook.github.io/react/docs/animation.html
Is there a way to change transitionName="example"
to have it take an object instead of string? transitionName={styles.example}
Upvotes: 0
Views: 33
Reputation: 474
Here are examples from the docs: https://facebook.github.io/react/docs/animation.html#custom-classes
// ...
<ReactCSSTransitionGroup
transitionName={ {
enter: 'enter',
enterActive: 'enterActive',
leave: 'leave',
leaveActive: 'leaveActive',
appear: 'appear',
appearActive: 'appearActive'
} }>
{item}
</ReactCSSTransitionGroup>
<ReactCSSTransitionGroup
transitionName={ {
enter: 'enter',
leave: 'leave',
appear: 'appear'
} }>
{item2}
</ReactCSSTransitionGroup>
// ...
Upvotes: 1