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 trialRashad Nelson
6,532 PointsWhen typing console.log("Message Destroyed"); does not open in console window
When typing console.log("Message Destroyed"); does not open in console window. All other commands work just not console display message.
3 Answers
Caleb Kemp
12,755 PointsSo, the console window doesn't automatically open on his code either. The console.log message just displays the message in the console. If you want to view the console message you have to open the console. You can do this by right-clicking on the page, selecting "inspect", and clicking the "console" tab. You can also do this as Guil does it with a key code shortcut (which makes it look automatic), using "Ctrl + Shift + J" (or Cmd + Shift + J on a Mac. Here is a page which has additional information on that. Hope that helps
Charlie Palmer
15,445 PointsConsole would never automatically open just because there is a console.log in the js. There are many websites where there are things being logged in the console but doesn't automatically open the console. The user of any website should never need to open the console for any reason and so it doesn't open for them. console.log is a method whcih people use for temporary debugging and lazy testing for their coding since it provides a simple and easy solution for testing their code. For example, to see what i mean you should just go to youtube and then open the console. You will most likely see messages in the console. Also if this automatically opened the console when there was a console.log, then this would be really inconvenient. Image if a developer accidentlally left a console.log in their code and then a user of their website was to press on something and then their console opened on their page since the dev forgot to remove the console message?
Dylan Bailey
Front End Web Development Techdegree Graduate 17,232 PointsYou'll have to manually open the console to view logs.