Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions src/frameworks/cdkFramework.ts
Original file line number Diff line number Diff line change
Expand Up @@ -283,8 +283,9 @@ export class CdkFramework implements IFramework {
// for .mjs files, use js loader
const fileExtension = args.path.split('.').pop();
const loader: esbuild.Loader =
fileExtension === 'mjs' ? 'js' : (fileExtension as esbuild.Loader);

(fileExtension === 'mjs' || fileExtension === 'cjs')
? 'js'
: (fileExtension as esbuild.Loader);
// Inject code to get the file path of the Lambda function and CDK hierarchy
if (args.path.includes('aws-cdk-lib/aws-lambda/lib/function.')) {
const codeToFind =
Expand Down
Loading