如何在无服务器框架或AWS lambda中启用node js的实验性功能

How to enable experimental features of nodejs in serverless framework or AWS lamda

我正在为我的 nodejs 应用程序使用 Serverless-Framework,但应用程序需要启用 nodejs 的实验性功能,我如何使用 sls deploy cmd 在无服务器中执行此操作。或直接在 AWS lambda

如果特征在标志后面,您可以设置 NODE_OPTIONS env var, which lambda supports

如果该功能不在 AWS-provided node runtimes (as of late 2021 v14.x is the highest version), you can deploy a custom runtime or a Docker container 上。