1、設置 data-x ="y"
在事件處理函數中有個參數 e
e.currentevent.dataset.x可以得到y
2、設置id屬性 id = “y”
在事件處理函數中有個參數 e
e.currentevent.id可以得到y
1、設置 data-x ="y"
在事件處理函數中有個參數 e
e.currentevent.dataset.x可以得到y
2、設置id屬性 id = “y”
在事件處理函數中有個參數 e
e.currentevent.id可以得到y
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。