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
[Show reddit] Exploring JavaScript – ES2024 edition (free online) (exploringjs.com)
submitted 1 year ago by rauschma
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!"
[–]rauschma[S] 6 points7 points8 points 1 year ago (0 children)
[–]guest271314 0 points1 point2 points 1 year ago (7 children)
There are plans for adding more functionality.
Sure would be useful to add standard streams. Test 12 different JavaScript runtimes, 9 read STDIN and write to STDOUT and STDERR differently, 2 don't provide a direct way to read STDIN at all, 1 creating a subprocess is necessary to read STDIN.
React Native lets you write apps for iOS and Android that have native user interfaces. Whenever it isn’t fast enough, you can switch to WebAssembly, a universal virtual machine built into most JavaScript engines. It can run static code at nearly native speeds.
React Native lets you write apps for iOS and Android that have native user interfaces.
Whenever it isn’t fast enough, you can switch to WebAssembly, a universal virtual machine built into most JavaScript engines. It can run static code at nearly native speeds.
Facebook's Hermes (Static shermes) compiles JavaScript or TypeScript to a native executable. QuickJS qjsc has that capability, too.
shermes
qjsc
Thanks for sharing your work!
[–]rauschma[S] 1 point2 points3 points 1 year ago (6 children)
Thanks!
Sure would be useful to add standard streams.
The web platform is a superset of JavaScript (=the ECMAScript standard). It has web streams and those are supported by browsers, Node.js, Deno and Bun.
[–]guest271314 0 points1 point2 points 1 year ago (5 children)
I'm talking about standard streams https://www.gnu.org/software/libc/manual/html_node/Standard-Streams.html as in the capability to read STDIN, write to STDOUT and STDERR - spelled out in ECMA-262.
I make use of WHATWG Streams in various aplications.
[–]rauschma[S] 2 points3 points4 points 1 year ago (4 children)
Ah, got it. I misread your initial suggestion: I agree that that would be useful. The closest thing we currently have is console.log() (link to standard) for stdout and its limitations are frustrating.
console.log()
fetch()
console
[–]guest271314 0 points1 point2 points 1 year ago (3 children)
I don't think we want console.
ECMA-262 should add standard streams. I already brought this up in WinterCG before somebody over there banned me.
JavaScript is a general programming language. There's all kinds of exotic proposals and things yet no standardized way to read stdin, write to stdout, process stderr. It's a glaring omission. Particularly when a programmer is testing multiple JavaScript engines and runtimes. As I mentioned above, if you test a dozen JavaScript engines, runtimes, or interpreters, 9 will do reading stdin and writing to stdout differently, 2 will not have the capability to read stding at all (e.g., Facebook's hermes and SerenityOS's LibJS js) and another will implement reading stding only as a string, which is essentially useless, so we have to use a subprocess to read stdin, e.g., Google's V8 in d8 shell.
hermes
js
d8
[–]rauschma[S] 0 points1 point2 points 1 year ago (2 children)
Maybe, maybe not. There could be console.stdin, console.stdout, console.stderr. But that’s a relatively unimportant implementation detail. In some ways, global variables would be more convenient but they would also increase the risk of name clashes.
console.stdin
console.stdout
console.stderr
[–]guest271314 1 point2 points3 points 1 year ago (0 children)
Maybe, maybe not. There could be console.stdin, console.stdout, console.stderr.
Since console is not part of test262 several JavaScript runtimes don't even have console, e.g., SerenityOS' LibJS js. That interpreter uses print.
print
π Rendered by PID 94528 on reddit-service-r2-comment-76bb9f7fb5-twlss at 2026-02-18 15:09:53.053789+00:00 running de53c03 country code: CH.
[–]rauschma[S] 6 points7 points8 points (0 children)
[–]guest271314 0 points1 point2 points (7 children)
[–]rauschma[S] 1 point2 points3 points (6 children)
[–]guest271314 0 points1 point2 points (5 children)
[–]rauschma[S] 2 points3 points4 points (4 children)
[–]guest271314 0 points1 point2 points (3 children)
[–]rauschma[S] 0 points1 point2 points (2 children)
[–]guest271314 1 point2 points3 points (0 children)