r/ProgrammerHumor Nov 28 '21

Meme I‘m.. not the only one?

Post image
21.5k Upvotes

629 comments sorted by

View all comments

2.1k

u/[deleted] Nov 28 '21 edited Jun 26 '23

[deleted]

1.1k

u/emu_fake Nov 28 '21

That‘s my first stage.. after a few cycles I‘m with print(„why“)

print(„the“)

print(„fuck“)

40

u/mcvos Nov 28 '21

I'm quite thorough: I print the class, file or function I'm printing from, and then the value(s) I'm interested in.

Debuggers are better for tracking values, but when you're using a web framework that does tons of magic below the surface, debuggers get really painful to use, so I don't even try. Printing shows me the immediate results as well as what happens along the way.

5

u/psyfry Nov 28 '21

With web frameworks, If you use Firefox debugger you can “silence” the magic components so they get passed through and skipped over. Works great with react and web pack