4. 动态参数的设置
- state查询
- setState改变参数
具体代码可以参考我的github中的first-react
1.state进行查询
// App.js
class Content extends Component {
constructor(props) {
super(props);
this.state = {
content: '123'
};
}
render
具体代码可以参考我的github中的first-react
// App.js
class Content extends Component {
constructor(props) {
super(props);
this.state = {
content: '123'
};
}
render