摘要:
class Counter extends React.Component{ constructor(props,context) { super(props,context) this.state={ hou:0, second:0, minutes:0, strikes:0, } this.ti 阅读全文
posted @ 2020-03-15 14:14
whhhd
阅读(589)
评论(0)
推荐(0)
摘要:
1.直接在子组件中使用(不推荐) class child extends component{ render( <div>{this.props.value}</div> ) } 2.自己在构造函数中初始化一个值,在将 status 通过 componentWillReceiveProps 生命周期 阅读全文
posted @ 2020-03-15 10:13
whhhd
阅读(3808)
评论(0)
推荐(0)

浙公网安备 33010602011771号