Skip to content

Commit a1b4f83

Browse files
committed
'Random Background Color Changer' style: README.md update main README.md (variation_2)
1 parent 925e4aa commit a1b4f83

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

README.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,13 @@ In this project, you will help CamperBot build a random background color changer
3636
<h5>Step 5</h5>
3737
</summary>
3838
<p>
39-
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>
39+
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>.
40+
</p>
41+
<p>
4042
<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
4143
In this case, CamperBot is not passing in the correct selector to the <code>document.querySelector</code> method
44+
</p>
45+
<p>
4246
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>.
4347
</p>
4448
</details>

0 commit comments

Comments
 (0)