From d8f7aa99c2d8a0e3330611b15c6804dd20dcc9a2 Mon Sep 17 00:00:00 2001 From: daffl Date: Mon, 22 Jan 2024 12:55:19 -0800 Subject: [PATCH] fix(cli): Another fix for CLI ES module loading --- packages/generators/src/connection/index.ts | 2 +- packages/generators/src/service/index.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/generators/src/connection/index.ts b/packages/generators/src/connection/index.ts index 298599d249..43ab705556 100644 --- a/packages/generators/src/connection/index.ts +++ b/packages/generators/src/connection/index.ts @@ -90,7 +90,7 @@ export const generate = (ctx: ConnectionGeneratorArguments) => runGenerator( __dirname, 'templates', - ({ database }) => `${getDatabaseAdapter(database)}.tpl` + ({ database }) => `${getDatabaseAdapter(database)}.tpl.js` ), mergeJSON( ({ connectionString, database }) => diff --git a/packages/generators/src/service/index.ts b/packages/generators/src/service/index.ts index f02d5d3802..fa7b8f4536 100644 --- a/packages/generators/src/service/index.ts +++ b/packages/generators/src/service/index.ts @@ -210,4 +210,4 @@ export const generate = (ctx: ServiceGeneratorArguments) => } as ServiceGeneratorContext }) .then(runGenerators(__dirname, 'templates')) - .then(runGenerator(__dirname, 'type', ({ type }) => `${type}.tpl`)) + .then(runGenerator(__dirname, 'type', ({ type }) => `${type}.tpl.js`))