Hacker News new | past | comments | ask | show | jobs | submit login

The tradition of async programming goes back much further back than JS. Doing async I/O — usually referred to as event-driven programming — has been a popular technique in C and C++ for decades, with epoll(), kqueue, libevent/libev/libuv, Boost Asio, ASE, and so on. A lot of modern C software is built on async I/O, notably projects like Nginx, Memcached, Tor, Chrome, ntp, Redis, etc.



> has been a popular technique in C and C++ for decades, with epoll(), kqueue, libevent/libev/libuv, Boost Asio, ASE, and so on.

JavaScript is older than all of those. (Libuv in particular was harvested from Node, which was itself built on top of JavaScript.)

Obviously JS didn't invent callback-based async IO, but I think you're forgetting how old JS is and how relatively new that style of IO is.


This thread is about async/await, which was added to JavaScript in 2017. Before then, async programming was only done with Node.js (unless you consider windows.setTimeout() to be "event-driven programming"), which came out in 2009. Event-driven programming was an established paradigm years before then.


> This thread is about async/await, which was added to JavaScript in 2017.

The article is about async/await, but the comments I'm replying to seem to be about asynchronous programming in general. JS was doing async for many years before async/await was added.


Nobody was doing async JS before Node, which came long after async I/O was an established paradigm.


XMLHttpRequest shipped in 1999. AJAX was coined in 2005. The "A" in "AJAX" is for "asynchronous".


XMLHttpRequest may be async, but it's not an asynchronous programming model.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: