Update: I just chucked this up on npm so you can use it with:
npm i @small-tech/required
(See what I did there?) ;)
@aral cool trick, if you haven't done it already you should add a call to Error.captureStackTrace so your util functions aren't included in the stack trace
[Not related to the main topic ->] the RORO pattern can be useful on the long term when you need to add, rename or remove arguments to or from your functions.
@severo_bo Neat – thanks for the heads up :) I did do a cursory search to see if there was anything else out there but didn’t stumble on that :)
@severo_bo (I’m also a big fan of using parameter objects once you’re past a couple of paramaters for most things) :)
This is my personal Mastodon.