Skip to content

Commit 3ff4d89

Browse files
committed
'Random Background Color Changer' style: README.md update step-5 (variation_2)
1 parent a1b4f83 commit 3ff4d89

1 file changed

Lines changed: 10 additions & 9 deletions

File tree

__5__step__/README.md

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -5,15 +5,16 @@
55
<h4>Description of the task</h4>
66
</summary>
77
<h3>Step 5</h3>
8-
<p>
9-
CamperBot has created a new variable called <code>bgHexCodeSpanElement</code> to store the reference to the <code>span</code> element with the <code>id</code> of <code>bg-hex-code</code>. However, when they try to log that variable to the console, they get <code>null</code>.
10-
11-
<code>null</code> is a special value in JavaScript that represents the absence of a value. This can happen when you try to access a property of an object that doesn't exist.
12-
13-
In this case, CamperBot is not passing in the correct selector to the <code>document.querySelector</code> method.
14-
15-
Fix the <code>document.querySelector("bg-hex-code")</code> line so that it correctly selects the element with the <code>id</code> of <code>`bg-hex-code`</code>.
16-
</p>
8+
<p>
9+
CamperBot has created a new variable called <code>bgHexCodeSpanElement</code> to store the reference to the <code>span</code> element with the <code>id</code> of <code>bg-hex-code</code>. However, when they try to log that variable to the console, they get <code>null</code>.
10+
</p>
11+
<p>
12+
<code>null</code> is a special value in JavaScript that represents the absence of a value. This can happen when you try to access a property of an object that doesn't exist
13+
In this case, CamperBot is not passing in the correct selector to the <code>document.querySelector</code> method
14+
</p>
15+
<p>
16+
Fix the <code>document.querySelector("bg-hex-code")</code> line so that it correctly selects the element with the <code>id</code> of <code>bg-hex-code</code>.
17+
</p>
1718
</details>
1819

1920
# Random Background Color changer

0 commit comments

Comments
 (0)