摘要: 1、引入组件 2、state中设置选中状态 // button按钮的默认选中,0代表选中 state = { currentIndex: 0 } 3、设置class的样式,点击更改选中 selectNew(){ this.setState({currentIndex:0}); } selectOld 阅读全文
posted @ 2019-03-05 18:30 久巷 阅读(1996) 评论(0) 推荐(0) 编辑