问题 I am building a React component which delays the unmounting of its children in order to animate them. When unmounting, I would like to pass in an additional prop (for example, a data-attribute or a class name) in order to handle animations. This is a specific instance of a general situation where I want override certain properties of children. I have come to realize that the following pattern does exactly what I want: this.props.children.map(child => <child.type key={child.key} ref={child.ref