Closed
Description
Hey there,
I've created a repository that reproduces this issue here: https://github.com/endel/ts-node-graceful-shutdown-issue
All versions of ts-node
doesn't have the expected behaviour when gracefully shutting down a Node.js application.
ts-node
behaviour:
Process is dettached from terminal as soon as SIGINT
is received.
./node_modules/.bin/ts-node index.ts
^CGraceful shutdown started...
[21:22:41] endel:~/Projects/ts-node-graceful-shutdown-issue [master #]
$ Done, let's finish!
node
behaviour:
Process is dettached from terminal only after process.exit()
is called.
$ node index.js
^CGraceful shutdown started...
Done, let's finish!
[21:23:34] endel:~/Projects/ts-node-graceful-shutdown-issue [master #]
I believe ts-node
ideally should behave exactly how node
does, shouldn't it?
Thanks