Check whether component actually exists before

When using ReactCSSTransitionGroup and adding a node by replacing a null-child React will complain with a `TypeError: Cannot read property 'componentWillLeave' of undefined` the first time. This change fixes that.
Adding guad also for enter animations

Had `TypeError: 'undefined' is not an object (evaluating 'n.componentWillLeave')` pop up as well.
Merge branch 'pr/1852'