Thenables in Javascript

Sep 11, 2025

You can write custom awaitable (thenable) objects in javascript.

I think svelte (Rich harris 😅) mentioned using this to support the top level await that was introduced.

spiral into this while reading on how coroutines was designed in python.

thenables in js

thenables in js

/built-by-me

/learning

Thirdpen

Personalised interactive learning with AI

visit

/analytics

Littlestats

Fixed-cost analytics for makers

visit

/editor

DevCanvas

Build websites fast with AI

visit

/share

Project Name

A short sentence that gives an overall picture of the project

Project image 1Project image 2Project image 3Project image 4

Tech Stack

  • Stack1
  • Stack2
  • Stack3