When executing a local TypeScript module and using --require=ts-node/register option,
node was trying to resolve it inside the temporary npx folder.
This behaviour doesn't currently make sense, now modules required via this option
are always resolved relative from the current working directory of the script.
This currently prevents requiring a module that only exists in the npx context, but that could be added back easily if needed.
When executing a local TypeScript module and using
--require=ts-node/register
option, node was trying to resolve it inside the temporary npx folder. This behaviour doesn't currently make sense, now modules required via this option are always resolved relative from the current working directory of the script. This currently prevents requiring a module that only exists in the npx context, but that could be added back easily if needed.https://nodejs.org/docs/latest-v10.x/api/all.html#modules_require_resolve_request_options