I'm using styled-components instead of tradition way of css. But I don't know how it can work together with ReactCSSTransitionGroup.
Basically, ReactCSSTransitionGroup
looks for certain classnames in css resource, then apply to a component throughout its lifecycle. However, with styled-components
, there are not any class names, styles are applied to components directly.
I know I can choose not to use ReactCSSTransitionGroup
because the two technique doesn't look compatible. But when I use only styled-components
, seems I can't render any animation when a component is unmounted - it's pure css, can't access component's lifecycle.
Any help or recommendation is appreciated.