nowfound

Dev tools · November 5, 2023

TC

Ts-Chan – Go-Like Concurrency Primitives for TypeScript/JavaScript

Hey HN, I’m sharing ts-chan, an NPM package providing Go-like concurrency primitives, including channels and select statements, for TypeScript and JavaScript, supporting Node.js, Deno, Bun, and browsers. This is something I've built to make implementing Go-style "control loops" feasible in JavaScript, but there are many possible applications. Highlights: - Features a FIFO processing Chan class and versatile Select class for concurrency control. - Supports buffered channel and channel close semantics very close to Go's. - TypeScript-first implementation. - Defines a simple "channel protocol"…

In plain words

Ts-Chan is an NPM package that brings Go-style concurrency primitives to TypeScript and JavaScript, including channels and select statements. It provides a FIFO Chan class and Select class for managing concurrent operations, with support for buffered channels and close semantics similar to Go's implementation. The TypeScript-first tool works across Node.js, Deno, Bun, and browsers, enabling developers to build Go-style control loops in JavaScript environments.

written from the facts on this page · September 2026

From the sources

In the maker’s words, at launch

Hey HN, I’m sharing ts-chan, an NPM package providing Go-like concurrency primitives, including channels and select statements, for TypeScript and JavaScript, supporting Node.js, Deno, Bun, and browsers. This is something I've built to make implementing Go-style "control loops" feasible in JavaScript, but there are many possible applications. Highlights: - Features a FIFO processing Chan class and versatile Select class for concurrency control. - Supports buffered channel and channel close semantics very close to Go's. - TypeScript-first implementation. - Defines a simple "channel protocol" inspired by JavaScript's iteration protocols, that's used by `Select`, and implemented by `Chan`. - Makes an effort to mitigate cycles caused by the behavior of JavaScript's microtask queue. - Ongoing project with active iteration for a production-ready module (pre-v1, so the API isn't guaranteed to be stable, but the implementation itself is). NPM: ts-chan GitHub: github.com/joeycumines/ts-chan Thanks!

More dev tools this month

the category →
  • Dograh592

    The open source VAPI alternative

    Dev tools · 25d ago · dograh.com

  • Meridian530

    Don't let your work go unnoticed. Get promoted!

    Dev tools · 20d ago · meridiona.com

  • x1516

    Lovable for iPhone apps go from idea to App Store

    Dev tools · 11d ago · x1.new

  • Open-source GTM skills for technical founders

    Dev tools · 29d ago · gtmcofounder.com

  • OpenTrailPaper is open-source bike computer firmware for the LilyGO T5S3 4.7" E-Paper PRO. It supports offline maps, GPX routes, FIT recording and Bluetooth sensors.

    Dev tools · 1d ago · opentrailpaper.com

  • Nuphos380

    The AI-Native DevOps Workspace.

    Dev tools · 24d ago · nuphos.ai

Launched alongside, November 2023

the whole month →
  • Flowla1,120

    Digital sales rooms that wow buyers

    Growth · 2023 · flowla.com

  • Discover & book top creators to promote your product

    Growth · 2023 · passionfroot.me

  • Re:catch939

    If Google Form & Calendly had a baby

    Growth · 2023 · recatch.cc

  • Pitch 2.0887

    Create, share and analyze presentations faster than ever

    Work · 2023 · pitch.com

  • CRM built for modern teams & creators powered by AI

    AI · 2023 · leaddelta.com

  • Make your website lightning fast

    Dev tools · 2023 · speedvitals.com