2 ms·
As an obsessive readonly-er, yeah this pain is real. It basically colors your functions the way async does. There is a TS issue I haven’t checked on in a while
by eyelidlessness 4y ago
As an obsessive readonly-er, yeah this pain is real. It basically colors your functions the way async does. There is a TS issue I haven’t checked on in a while about readonly-by-default and a corresponding mutable keyword. I doubt it got much traction, but it’s a shame.
Writing Clojure I really liked that there was a baseline assumption that functions are pure and a clear signal in code when it’s stateful. It doesn’t have to color functions (but ahem it works great for Haskell), but it seems like a reasonable opt-in default that shouldn’t be so painful.