faastjs.commonoptions.include.md

April 11, 2023 ยท View on GitHub

faastjs > CommonOptions > include

CommonOptions.include property

Include files to make available in the remote function. See IncludeOption.

Signature:

include?: (string | IncludeOption)[];

Remarks

Each include entry is a directory or glob pattern. Paths can be specified as relative or absolute paths. Relative paths are resolved relative to the current working directory, or relative to the cwd option.

If the include entry is a directory "foo/bar", the directory "./foo/bar" will be available in the cloud function. Directories are recursively added.

Glob patterns use the syntax of node glob.

Also see CommonOptions.exclude for file exclusions.