3 ms·
is `send2` supposed to be the node version of UNIX `sendto(2)`? [1] I don't see `send2` in the node docs[2]. [1] https://beej.us/guide/bgnet/html/#sendtorecv
by trillic 4y ago
is `send2` supposed to be the node version of UNIX `sendto(2)`? [1]
I don't see `send2` in the node docs[2].
[1] https://beej.us/guide/bgnet/html/#sendtorecv https://beej.us/guide/bgnet/html/#sendtorecv
[2] https://nodejs.org/api/dgram.html https://nodejs.org/api/dgram.html
- asciii 4y ago> Note: We promisify our socket.send function for two reasons: Using await makes the flow of our code sequential. We want to call socket.close after all messages are sent Hence the use of send2