@Generated(value="jsii-pacmak/1.47.0 (build 86d2c33)", date="2021-12-20T00:39:28.832Z") @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 List<String> |
getExternals()
(experimental) You can mark a file or a package as external to exclude it from your build.
|
default Boolean |
getSourcemap()
(experimental) Include a source map in the bundle.
|
default Boolean |
getWatchTask()
(experimental) In addition to the `bundle:xyz` task, creates `bundle:xyz:watch` task which will invoke the same esbuild command with the `--watch` flag.
|
@Stability(value=Experimental) @Nullable default List<String> getExternals()
Instead of being bundled, the import will be preserved (using require for the iife and cjs formats and using import for the esm format) and will be evaluated at run time instead.
This has several uses. First of all, it can be used to trim unnecessary code from your bundle for a code path that you know will never be executed. For example, a package may contain code that only runs in node but you will only be using that package in the browser. It can also be used to import code in node at run time from a package that cannot be bundled. For example, the fsevents package contains a native extension, which esbuild doesn't support.
Default: []
@Stability(value=Experimental) @Nullable default Boolean getSourcemap()
Default: false
@Stability(value=Experimental) @Nullable default Boolean getWatchTask()
This can be used to continusouly watch for changes.
Default: true
@Stability(value=Experimental) static BundlingOptions.Builder builder()
BundlingOptions.Builder of BundlingOptionsCopyright © 2021. All rights reserved.