Skip to content

Commit 9094c49

Browse files
authored
Merge pull request #4 from javascript-info/master
2 parents 3b97fa8 + 3724c4e commit 9094c49

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

2-ui/1-document/11-coordinates/head.html

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
<script>
22
document.addEventListener('DOMContentLoaded', function() {
33

4-
document.getElementById('coords-show-mark').onclick = function() {
5-
let elem = document.getElementById("coords-show-mark");
4+
let elem = document.getElementById('coords-show-mark');
5+
6+
elem && elem.onclick = function() {
67

78
function createMessageUnder(elem, text) {
89
let coords = elem.getBoundingClientRect();

0 commit comments

Comments
 (0)