From b53f1be850096da66b23d95eb490f0e884c70ed2 Mon Sep 17 00:00:00 2001 From: Shrujal Shah Date: Wed, 20 Oct 2021 02:32:55 +0530 Subject: [PATCH] update version checks for v16 Ref: https://github.com/nodejs/node/pull/40504 --- src/esm.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/esm.ts b/src/esm.ts index 5502d0155..c95ceace5 100644 --- a/src/esm.ts +++ b/src/esm.ts @@ -54,10 +54,10 @@ export function createEsmHooks(tsNodeService: Service) { }); // The hooks API changed in node version X so we need to check for backwards compatibility. - // TODO: When the new API is backported to v12, v14, v16, update these version checks accordingly. + // TODO: When the new API is backported to v12, v14, update these version checks accordingly. const newHooksAPI = versionGteLt(process.versions.node, '17.0.0') || - versionGteLt(process.versions.node, '16.999.999', '17.0.0') || + versionGteLt(process.versions.node, '16.20.0') || versionGteLt(process.versions.node, '14.999.999', '15.0.0') || versionGteLt(process.versions.node, '12.999.999', '13.0.0');