async hooks node track async-hooks execution as linked-list. API // export type Node = {// parent?: Node// asyncId: number// } import { executionAsyncNode } from 'async-hooks-node';const node1 = executionAsyncNode() setTimeout(() => { const node2 = executionAsyncNode() // node2.parent == node1}, 1); it is easily to implement any thread-local like async-context with extending Node or using WeakMap.