回答編集履歴
1
あ
answer
CHANGED
@@ -1,8 +1,10 @@
|
|
1
1
|
```
|
2
|
+
function hello(event){console.log(event)}
|
2
3
|
window.addEventListener('click', hello);
|
3
|
-
function hello(event){console.log(event)}
|
4
4
|
```
|
5
5
|
|
6
|
+
Windowをクリックすると、イベントオブジェクトがhelloに渡されます。
|
7
|
+
|
6
8
|
```
|
7
9
|
MouseEvent {isTrusted: true, screenX: 230, screenY: 542, clientX: 230, clientY: 408, …}
|
8
10
|
```
|