this post was submitted on 17 Aug 2024
705 points (95.1% liked)
Programmer Humor
32495 readers
301 users here now
Post funny things about programming here! (Or just rant about your favourite programming language.)
Rules:
- Posts must be relevant to programming, programmers, or computer science.
- No NSFW content.
- Jokes must be in good taste. No hate speech, bigotry, etc.
founded 5 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
I'd just like to highlight what you mention below: Logging it as an object allows you to inspect it in the browser console, presumably with some JSON tree representation, rather than just a dumb string.
It's described in the "Outputting a single object" example here: https://developer.mozilla.org/en-US/docs/Web/API/console#examples