Execute Typescript code inside Serverless config

512 Views Asked by At

I use Serverless framework to deploy my backend. My lambdas are written in Typescript and I deploy them using serverless-webpack plugin. Serverless allows to reference variables in javascript files using syntax:

# serverless.yml
service: new-service
provider: aws

custom: ${file(../config.js)}

But it works for javascript. How can I do the same with Typescript code? My goal is to have all project code written in Typescript.

0

There are 0 best solutions below