While working on my sample App using the CDK
, I encountered some questions. I made changes to the stack.ts
file in my project, and then ran cdk synth
and cdk deploy
. Surprisingly, it appears that compiling to JavaScript was not necessary for my project.
Upon inspecting the cdk.json
file, I found the following command:
"app": "npx ts-node --prefer-ts-exts bin/cdk.ts"
It seems that cdk.ts
serves as the endpoint for my stack, and there doesn't seem to be any issues even if I only work in TypeScript.
Is compiling to JavaScript really unnecessary for CDK development? Are there any potential problems with this approach? If I have misunderstood any crucial concepts, could you please clarify? Thank you!