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 trialJustin Townsend
4,720 PointsI am really sorry but i have no clue what i am doing I watched the videos 5 times already and still I have no clue
how do I make this a JQuery file and how do I had a hide()?
1 Answer
Liam Clarke
19,938 PointsHi Justin
The challenge is asking you to convert the vanilla JavaScript into JQuery.
remember JQuery is just a javascript library so it lives within a normal javascript file extension.
The difference is JQuery has these helpful functions that do all this long JavaScript code for us.
The hide() function replaces the style.display = 'none';
// This line of code
document.querySelector('.profile-header').style.display = 'none';
//Is identical to this line of code
$('.profile-header').hide();
JQuery has many helpful functions just like this one, check out the documentation for more
Good Luck
Justin Townsend
4,720 PointsJustin Townsend
4,720 PointsMr. Clarke thank you so much I really appreciate your help!