8 ms·
Wonder what the author thinks about https://effect.website/ https://effect.website/
by rohan_ 2y ago
Wonder what the author thinks about https://effect.website/ https://effect.website/
- phildenhoff 2y agoDoes Effect prevent workers that have uncaught exceptions from crashing the main thread in Node? Does it reduce the amount of memory workers use?
- dyl000 2y agoI’d assume effect would increase how much memory JS uses, you’re creating a bunch of memory junk. In theory it should make you able to contain errors with exception handing.
- dyl000 2y agoI like ideas from effect, I use my custom result type all over my application as well as my custom tryCatch & promise.allSettled wrappers. Issue comes down to you need to wrap all of your code in effect/results. Something like rust has that built in so you're not really 'jamming' it in there. It adds a bunch of boilerplate. Still better than the mess that is exception throwing.
- josh_p 2y agoThanks for this! I didn’t know this library existed. I’ve used a couple of other small libraries to get rust-like error handling and patterns into my Typescript projects. But this is way more comprehensive. I’m going to give it a try.