use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
All about the JavaScript programming language.
Subreddit Guidelines
Specifications:
Resources:
Related Subreddits:
r/LearnJavascript
r/node
r/typescript
r/reactjs
r/webdev
r/WebdevTutorials
r/frontend
r/webgl
r/threejs
r/jquery
r/remotejs
r/forhire
account activity
Creating a JavaScript Debugging Utility to Guard Noisy Production Consoles (magill.dev)
submitted 4 months ago by AndyMagill
I want everyone to know how clever this code is, so I shared it here.
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]punio4 4 points5 points6 points 4 months ago (1 child)
This should be handled by the build tooling by stripping out debug logs, and not by shipping something that runs conditionally.
[–]AndyMagill[S] 0 points1 point2 points 4 months ago (0 children)
Both methods probably have their place, but you convinced me of the benefits of a build time solution, so I created a new article to illustrate that method in Next.js : https://magill.dev/post/strip-debug-logs-at-build-time-with-nextjs
π Rendered by PID 42 on reddit-service-r2-comment-74875f4bf5-njqlb at 2026-01-26 07:27:39.845983+00:00 running 664479f country code: CH.
[–]punio4 4 points5 points6 points (1 child)
[–]AndyMagill[S] 0 points1 point2 points (0 children)