1. Describe your problem
props,componentWillRecivePropprops2
2. Code
UI:
<Popover
visible={popBotVisible}
placement="left"
keyName="footer"
>
</Popover>
<Popover
visible={popTopVisible}
placement="top"
keyName="header"
>
</Popover>
constructor(props) {
super(props);
this.state = {
popMainShow:false,
keyName:props.keyName,
placement:props.placement,
popContent:props.popContent,
}
}
componentWillReceiveProps(props){
console.log(nextProps) // console
}
3. Expect
the life cycle function and state of each Popover you want to create are independent, and can only accept their own props