質問編集履歴

1

追記

2022/01/23 19:05

投稿

teratailer
teratailer

スコア46

test CHANGED
File without changes
test CHANGED
@@ -18,8 +18,9 @@
18
18
  });
19
19
 
20
20
  Array.from(document.querySelectorAll("input[type='button']"), i => {
21
+ i.onclick="";
21
22
  i.addEventListener('click', function() {
22
- alert("hello");
23
+ alert("hello");//alertが2回出ることから上書きされない
23
24
  });
24
25
  });
25
26