This is ingenious, but as far as I know, not a standard node pattern, and could be confusing to some.
Asynchronous functions are recommended in general because they mean your server is non-blocking and can deal with more requests. However, for things that happen before the server is running, there is no reason not to use sync methods if they make your life easier, because concurrency is not a requirement.
This is ingenious, but as far as I know, not a standard node pattern, and could be confusing to some.
Asynchronous functions are recommended in general because they mean your server is non-blocking and can deal with more requests. However, for things that happen before the server is running, there is no reason not to use sync methods if they make your life easier, because concurrency is not a requirement.