r/node • • Nov 06 '18

Basics: How to stop using console.log() and start using your browser’s debugger

https://medium.com/datadriveninvestor/stopping-using-console-log-and-start-using-your-browsers-debugger-62bc893d93ff
0 Upvotes

5 comments sorted by

4

u/GeneralIncompetence Nov 06 '18

Useful for the complete novice, but is /r/node the best place to post it, seeing as it's browser debugging?

2

u/[deleted] Nov 06 '18

And how will you do it on the server side where you actually want to log?

1

u/WakeskaterX Nov 07 '18

VSCode and the built in Node Debugger ;)

Love that thing - works like magic compared to using node inspector years ago.

1

u/phitruongdn Nov 06 '18

Front-end only!

1

u/daveequalscool Nov 06 '18

on the topic of moving past console.log, i spent the weekend integrating my first project with Winston for logging and am loving it. right now i just have api calls and model snapshots being logged and a basic reporter that pops either one (or a raw combined view) into a new window, formatted with tables. but having the full picture in one view without having to click through requests in the network panel is huge. especially since the project is based off another company's API, and client demos usually consist of showing the data to the client to prove that the bugs aren't ours.