Message from JavaScript discussions

January 2019

β€” But i think it will conquer minds of async freaks🀀


1. A general solution for handling async should be composable, in that it should model return values and eventual failures in a way that is flat and repeatable, halting is just too primitive to be practical for these things, promises allows us to not care about whether or not it's async since it has the composable property.

2. I won't.

3. Lots of things, safety for instance.

4. I won't, and rest of JS community won't either.

β€” It's a normal threading primitive, hence it doesn't make sense in JS

β€” It's like a spinlock

β€” Terrible

β€” What about the opposite?

β€” If you had the ability to spawn threads and not wait for them

β€” Any shared resource implies waiting

β€” So you could just do:

let x = true;

fork(() => {
x = false;

while (x);


β€” Only shared state

β€” If it's immutable you never have to wait

β€” This is how Go works