@Generated(value="jsii-pacmak/1.14.1 (build 828de8a)", date="2020-11-24T22:28:38.236Z") @Stability(value=Experimental) public interface BundlingOptions extends software.amazon.jsii.JsiiSerializable
| Modifier and Type | Interface and Description |
|---|---|
static class |
BundlingOptions.Builder
A builder for
BundlingOptions |
static class |
BundlingOptions.Jsii$Proxy
An implementation for
BundlingOptions |
| Modifier and Type | Method and Description |
|---|---|
static BundlingOptions.Builder |
builder() |
default Map<String,String> |
getBuildArgs()
(experimental) Build arguments to pass when building the bundling image.
|
default BundlingDockerImage |
getBundlingDockerImage()
(experimental) A custom bundling Docker image.
|
default Map<String,String> |
getBundlingEnvironment()
(experimental) Environment variables defined when bundling runs.
|
default String |
getEsbuildVersion()
(experimental) The version of esbuild to use when running in a Docker container.
|
default List<String> |
getExternalModules()
(experimental) A list of modules that should be considered as externals (already available in the runtime).
|
default Boolean |
getForceDockerBundling()
(experimental) Force bundling in a Docker container even if local bundling is possible.
|
default Map<String,String> |
getLoader()
(experimental) Use loaders to change how a given input file is interpreted.
|
default Boolean |
getMinify()
(experimental) Whether to minify files when bundling.
|
default List<String> |
getNodeModules()
(experimental) A list of modules that should be installed instead of bundled.
|
default Boolean |
getSourceMap()
(experimental) Whether to include source maps when bundling.
|
default String |
getTarget()
(experimental) Target environment for the generated JavaScript code.
|
@Stability(value=Experimental) @Nullable default Map<String,String> getBuildArgs()
Default: - no build arguments are passed
@Stability(value=Experimental) @Nullable default BundlingDockerImage getBundlingDockerImage()
This image should have esbuild installed globally. If you plan to use nodeModules
it should also have npm or yarn depending on the lock file you're using.
See https://github.com/aws/aws-cdk/blob/master/packages/%40aws-cdk/aws-lambda-nodejs/lib/Dockerfile for the default image provided by @aws-cdk/aws-lambda-nodejs.
Default: - use the Docker image provided by
@Stability(value=Experimental) @Nullable default Map<String,String> getBundlingEnvironment()
Default: - no environment variables are defined.
@Stability(value=Experimental) @Nullable default String getEsbuildVersion()
Default: - latest v0
@Stability(value=Experimental) @Nullable default List<String> getExternalModules()
Default: ['aws-sdk']
@Stability(value=Experimental) @Nullable default Boolean getForceDockerBundling()
This is useful if your function relies on node modules
that should be installed (nodeModules) in a Lambda compatible
environment.
Default: false
@Stability(value=Experimental) @Nullable default Map<String,String> getLoader()
Configuring a loader for a given file type lets you load that file type with
an import statement or a require call.
Default: - use esbuild default loaders
Example:
// Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826 {".png";"dataurl"; }
https://esbuild.github.io/api/#loader@Stability(value=Experimental) @Nullable default Boolean getMinify()
Default: false
@Stability(value=Experimental) @Nullable default List<String> getNodeModules()
Modules are installed in a Lambda compatible environnment only when bundling runs in Docker.
Default: - all modules are bundled
@Stability(value=Experimental) @Nullable default Boolean getSourceMap()
Default: false
@Stability(value=Experimental) @Nullable default String getTarget()
Default: - the node version of the runtime
https://esbuild.github.io/api/#target@Stability(value=Experimental) static BundlingOptions.Builder builder()
BundlingOptions.Builder of BundlingOptionsCopyright © 2020. All rights reserved.