Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialTrue Andrews
Front End Web Development Techdegree Student 10,520 PointsNot sure what I'm doing wrong
What am I doing wrong, what steps
<!DOCTYPE html>
<html lang="en">
<head>
<title>Document</title>
<link rel="stylesheet" href="style.css" type="text/css" media="screen" title="no title" charset="utf-8">
</head>
<body>
<h2>Star Trek Characters</h2>
<ul class="character-list">
<li>Captain Jean Luc Picard</li>
<li>Data</li>
<li>Worf</li>
<li>Dr. Crusher</li>
</ul>
<div>I am supposed to stay hidden!</div>
<script
src="jquery-3.2.1.min.js"></script>
<script src="app.js"></script>
</body>
</html>
const $show = $(div, li:hidden);
$show.show();
2 Answers
Fran ADP
6,304 Pointsreveal just the hidden the div.
Steven Parker
231,236 Pointsyou're on the right track, but I see 3 issues:
- the instructions say to reveal just the hidden li's, not the div
- the selector must be enclosed in quotes
- use method chaining to avoid creating a variiable
Steven Parker
231,236 PointsSteven Parker
231,236 PointsNo, not the div. Just the list items. The instructions say "... while leaving the <div> element hidden".