lambda-live-debugger 1.2.2 → 1.2.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -324,6 +324,7 @@ If you have a new feature idea, please create and issue.
324
324
 
325
325
  (alphabetical)
326
326
 
327
+ - [Kristian Dreher](https://www.linkedin.com/in/kristiandreher)
327
328
  - [Roger Chi](https://rogerchi.com/)
328
329
  - [Sebastian Bille](https://blog.sebastianbille.com)
329
330
  - ⭐ Your name here for notable code or documentation contributions or sample projects submitted with a bug report that resulted in tool improvement.
@@ -29,6 +29,7 @@ export async function getConfigTsFromConfigFile(configFile) {
29
29
  format: 'esm',
30
30
  outfile: compileOutput,
31
31
  sourcemap: true,
32
+ treeShaking: true,
32
33
  banner: {
33
34
  js: [
34
35
  `import { createRequire as topLevelCreateRequire } from 'module';`,
Binary file
@@ -195,7 +195,9 @@ export class CdkFramework {
195
195
  else {
196
196
  contents = fileContent;
197
197
  }
198
- const loader = args.path.split('.').pop();
198
+ // for .mjs files, use js loader
199
+ const fileExtension = args.path.split('.').pop();
200
+ const loader = fileExtension === 'mjs' ? 'js' : fileExtension;
199
201
  // Inject code to get the file path of the Lambda function and CDK hierarchy
200
202
  if (args.path.includes('aws-cdk-lib/aws-lambda/lib/function.')) {
201
203
  const codeToFind = 'try{jsiiDeprecationWarnings().aws_cdk_lib_aws_lambda_FunctionProps(props)}';
@@ -218,12 +220,12 @@ export class CdkFramework {
218
220
  };
219
221
 
220
222
  // console.log("CDK INFRA: ", {
221
- // stackName: lambdaInfo.stackName,
222
- // codePath: lambdaInfo.codePath,
223
- // code: lambdaInfo.code,
224
- // handler: lambdaInfo.handler,
225
- // bundling: lambdaInfo.bundling
226
- // });
223
+ // stackName: lambdaInfo.stackName,
224
+ // codePath: lambdaInfo.codePath,
225
+ // code: lambdaInfo.code,
226
+ // handler: lambdaInfo.handler,
227
+ // bundling: lambdaInfo.bundling
228
+ // });
227
229
  global.lambdas.push(lambdaInfo);` + codeToFind);
228
230
  }
229
231
  if (args.path.includes('aws-cdk-lib/aws-s3-deployment/lib/bucket-deployment.')) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "lambda-live-debugger",
3
- "version": "1.2.2",
3
+ "version": "1.2.4",
4
4
  "type": "module",
5
5
  "description": "Debug Lambda functions locally like it is running in the cloud",
6
6
  "repository": {