node-api: faster threadsafe_function
Invoke threadsafe_function during the same tick and avoid marshalling costs between threads and/or churning event loop if either:
- There's a queued call already
-
Push()
is called while the main thread was running threadsafe_function