vue 監聽鍵盤事件

    在使用鍵盤監聽鍵盤事件時直接綁定沒有任何反應。  this 直接在生命週期中進行綁定就能夠了。spa created : function(){ let _this = this; document. onkeydown = function( e){ let _key = window. event. keyCode; if( _key === 13){ _this. login( 1)
相關文章
相關標籤/搜索