dkfr.net
当前位置:首页 >> this.sEtstAtE Es6 >>

this.sEtstAtE Es6

解决方法 可以参照这个代码试一试。 const { quotes } = require('./quotes.json') classQuoteScreen extends Component { state = { QuoteIndex: 0 } handleUpdateState = () => { this.setState(({ QuoteIndex }) => ({ QuoteIndex: (QuoteInd...

把 export 去掉,另外应在constructor中定义state class LikeButton extends React.Component { constructor(props){ super(props); this.state = {switch: false}; this.handleClick = this.handleClick.bind(this); } handleClick(event) { th...

把 export 去掉,另外应在constructor中定义state class LikeButton extends Reactponent { constructor(props){ super(props); this.state = {switch: false}; this.handleClick = this.handleClick.bind(this); } handleClick(event) { this.s...

网站首页 | 网站地图
All rights reserved Powered by www.dkfr.net
copyright ©right 2010-2021。
内容来自网络,如有侵犯请联系客服。zhit325@qq.com