Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed Debug Node Applications with Visual Studio Code!
You have completed Debug Node Applications with Visual Studio Code!
Preview
There's more to debugging Node.js programs than logging values in your code. In general, console.log can be problematic, but you can overcome those problems using the Visual Studio Code editor's built-in debugger.
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign upRelated Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
[MUSIC]
0:00
Debugging is the process of identifying
and fixing defects in a program.
0:00
When you think about debugging one method
that might come to mind is writing
0:04
console.log statements to try to
identify what's gone wrong in your code.
0:08
The console.log method is native to Node
JS, where it prints to the terminal.
0:12
Similar to the way it prints to the web
browser's console when used in client side
0:16
JavaScript.
0:20
With console.log you can, for example,
take snapshots of variables at specific
0:21
moments in your program, which gives you
insight into where things are going wrong.
0:25
While console.log may be a tried,
and true, and
0:29
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up