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 trialJames Cocker
3,429 PointsAdd the button markup directly in the HTML?
Rather than using jQuery to insert the button markup, is there anything wrong with just adding it to the HTML file, and then using jQuery to hide/show it as required?
My thoughts are that the HTML is then all in one place, rather than putting HTML in the .js file.
2 Answers
Frank Stepanski
Full Stack JavaScript Techdegree Student 1,565 PointsButton markup as in what exactly?
James Cocker
3,429 PointsSee the related video. <button>Reveal the spoiler!</button>
James Barnett
39,199 PointsJames Barnett
39,199 PointsIf you look to right under the big green "start discussion" button is "related content". Check out the video linked there.