From bb26bf913524649da079fcd4bd42680cc7060daf Mon Sep 17 00:00:00 2001 From: Tom McLaughlin Date: Mon, 21 Oct 2024 21:06:28 -0400 Subject: [PATCH] try ESM once more --- package.json | 1 + template.yaml | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index d9ce733..cf620af 100644 --- a/package.json +++ b/package.json @@ -2,6 +2,7 @@ "name": "serverlessops-catalog-api", "version": "0.0.1", "description": "ServerlessOps Catalog API for Backstage", + "type": "module", "repository": { "type": "git", "url": "git@github.com:ServerlessOpsIO/serverlessops-catalog-api.git" diff --git a/template.yaml b/template.yaml index 4331e29..ec095e1 100644 --- a/template.yaml +++ b/template.yaml @@ -79,9 +79,10 @@ Resources: BuildProperties: Minify: true Target: "es2020" + Format: "esm" Sourcemap: !Ref EnableSourceMaps OutExtension: - - .js=.cjs + - .js=.mjs EntryPoints: - function.js @@ -106,9 +107,10 @@ Resources: BuildProperties: Minify: true Target: "es2020" + Format: "esm" Sourcemap: !Ref EnableSourceMaps OutExtension: - - .js=.cjs + - .js=.mjs EntryPoints: - function.js