第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號安全,請及時綁定郵箱和手機(jī)立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

onClick 觸發(fā)單擊錯誤:current.click 不是函數(shù)

onClick 觸發(fā)單擊錯誤:current.click 不是函數(shù)

白板的微信 2021-08-20 10:32:32
我正在嘗試在另一個 onClick 事件函數(shù)上觸發(fā)單擊按鈕。錯誤:未捕獲的類型錯誤:this.clickBack.current.click 不是函數(shù)React 版本是 16.8.6constructor(props) {    super(props)    this.clickBack = React.createRef();    this.startInterview = this.startInterview.bind(this);}startInterview(){    console.log('hello') // output : hello    console.log(this.clickBack.current); // output : Button {props: {…}, context: {…}, refs: {…}, updater: {…}, onClick: ?, …}    this.clickBack.current.click(); // output : Uncaught TypeError: this.clickBack.current.click is not a function}在渲染 -> 返回方法中<Link to={backLink}>    <Button ref={this.clickBack}> Back</Button></Link><Button onClick={this.startInterview}> Start Interview</Button>
查看完整描述

2 回答

  • 2 回答
  • 0 關(guān)注
  • 362 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學(xué)習(xí)伙伴

公眾號

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號