diff --git a/packages/core/src/constants.ts b/packages/core/src/constants.ts index 232d5cebe..baa91fbb3 100644 --- a/packages/core/src/constants.ts +++ b/packages/core/src/constants.ts @@ -6,4 +6,4 @@ export const cjsRequire = typeof require === 'undefined' ? createRequire(import.meta.url) : require // eslint-disable-next-line n/no-deprecated-api, sonar/deprecation -export const EXTENSIONS = ['.ts', '.tsx', ...Object.keys(cjsRequire.extensions)] +export const EXTENSIONS = ['.ts', '.tsx', ...Object.keys(cjsRequire.extensions || {})]