react怎么给绑定的onclick事件传递除event对象之外
2020-04-27 本文已影响0人
SmileMylife
例:
render( <div> <a onclick = {this.dealOnclick.bind(this, "参数1", "参数2")}>点击</a> </div> ) dealOnclick = (canshu1, canshu2, event) => { console.log(canshu1); console.log(canshu2); console.log(event); }