Skip to content

Separating functions folder into build folder and src folder #287

@peter-wd-1

Description

@peter-wd-1

This is one of two requests in #276

Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

Hi,
I have lambda functions that have their own dependency and so need to use netlify-lambda install and It only detects build folder(relatively designated functions folder becomes build folder because there is no way to specify it as src folder). If I want to separate src folder and build folder for functions, I need to specify netlify-lambda install and I can't install with just one line of the script. Instead, I need to specify all the lambda functions folder with the install command. I think this is very handful way of installing functions. I really can't think of use case that netlify-lambda install would not need to check all lambda folders and install each dependency(Users love convenience as we all know).

Describe the solution you'd like
A clear and concise description of what you want to happen.

In netlify.toml, I would like to designate two different folders for src and build like below:

functions-src = "./src/functions"
functions-build = "./functions-build"

With just one line of code for installing dependency of all functions in package.json.

"scripts":{
  "postinstall": "netlify-lambda install",
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: featurecode contributing to the implementation of a feature and/or user facing functionality

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions