Skip to content

Commit df564f7

Browse files
committed
Update DOM - Show anchors.js
1 parent fc732c0 commit df564f7

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

javascripts/DOM - Show anchors.js

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
"use strict";
2+
var i, anchor, name;
23
var anchors = document.anchors;
34
for (i = 0; i < anchors.length; i += 1) {
4-
var anchor = anchors[i];
5-
var name = anchor.name;
5+
anchor = anchors[i];
6+
name = anchor.name;
67
if (name !== undefined && name.length > 0) {
7-
anchor.appendChild(document.createTextNode("#" + name));
8+
anchor.appendChild(document.createTextNode("#" + name));
89
}
910
}

0 commit comments

Comments
 (0)