Node.js · Junior · Question 73 of 75
Which statement about console.log in a high-traffic server is true?
- 1It does nothing in production mode
- ✓Correct answer: It's fine for debugging, but production apps usually use a structured logger like Pino with log levels
- 3It's the fastest possible logging method, so it's always preferred
Explanation
Structured JSON logs with levels (info, warn, error) and fields like request ID are easy to search and filter in log systems.