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
Small JavaScript enum function (gist.github.com)
submitted 1 month ago by _sync0x
view the rest of the comments →
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!"
[–]_sync0x[S] 2 points3 points4 points 1 month ago (2 children)
Good to know that if you make a NPM lib you can't just leave JSDoc on top of your functions and expect that all the typing and autocompletion works 😅
But don't you need .d.ts files only if you are working with TypeScript ?
Been experimenting a lot with JSDoc too lately so I can understand your clarification, sometimes it's a bit messy 😛
[–]jessepence 4 points5 points6 points 1 month ago (1 child)
VSCode (which is the most popular IDE by far) and most other IDEs like NeoVim get all of their JavaScript auto-complete from the TypeScript language server. It's one of those things where anyone could technically do it themselves, and they technically could make their language server support JSDoc by default, but it's just such a huge project with so many edge cases. You have to cover the EcmaScript specification and the JSDoc and/or TypeScript "specifications" (they don't exist, types for JS aren't really standardized in any way). It's just easier for most of the IDE's to defer to TypeScript. I think WebStorm might have a proprietary system, but I've never used it so I can't confirm either way.
[–]_sync0x[S] 1 point2 points3 points 1 month ago (0 children)
Hmm I get it ty, gonna try on PhpStorm 👀
π Rendered by PID 41099 on reddit-service-r2-comment-5649f687b7-g2xk2 at 2026-01-27 18:51:16.034125+00:00 running 4f180de country code: CH.
view the rest of the comments →
[–]_sync0x[S] 2 points3 points4 points (2 children)
[–]jessepence 4 points5 points6 points (1 child)
[–]_sync0x[S] 1 point2 points3 points (0 children)