Yes, it does!
The idea of using tagged templates was taken from zx, and I think that was quite innovative!
However, with zx, the options are set using a bunch of mutable properties like $.verbose = true, or methods like .nothrow(). Besides having to remember each of those, I found that approach to have the following problems:
It requires mutating global state to share options between multiple commands.
Lots of core child_process options are not available. Some of them are quite useful! Like detached for background processes, for example.
So we opted to a single options binding method $(options), which works both for single commands, and multiple commands at once. There was lots of back-and-forth discussion about this, but I think it was worth it :)
Whoa, so the
tag
in a tagged template is an expression, rather than an ident? TIL, thanks!Yes, it does! The idea of using tagged templates was taken from zx, and I think that was quite innovative!
However, with zx, the options are set using a bunch of mutable properties like
$.verbose = true
, or methods like.nothrow()
. Besides having to remember each of those, I found that approach to have the following problems:child_process
options are not available. Some of them are quite useful! Likedetached
for background processes, for example.So we opted to a single options binding method
$(options)
, which works both for single commands, and multiple commands at once. There was lots of back-and-forth discussion about this, but I think it was worth it :)Zx author here. Super cool! Congrats š
Iām glad, zx inspired many people)
Also nice ideas)
Thanks Anton! This feature was definitely inspired by zx, I was also digging through your code :)
I like the $() feature. At the time, antongolub@ tried to convince me to add something like this. But I refused)