diff --git a/docs/esbuild.md b/docs/esbuild.md index 642dcf7..badb103 100644 --- a/docs/esbuild.md +++ b/docs/esbuild.md @@ -23,29 +23,29 @@ For further information about esbuild, see https://esbuild.github.io/ | Name | Description | Type | Mandatory | Default | | :------------- | :------------- | :------------- | :------------- | :------------- | | name | A unique name for this target. | Name | required | | -| args_file | Internal use only | Label | optional | None | -| config | Configuration file used for esbuild. Note that options set in this file may get overwritten. TODO: show how to write a config file that depends on plugins, similar to the esbuild_config macro in rules_nodejs. | Label | optional | None | -| data | Runtime dependencies to include in binaries/tests that depend on this target.

The transitive npm dependencies, transitive sources, default outputs and runfiles of targets in the data attribute are added to the runfiles of this taregt. Thery should appear in the '*.runfiles' area of any executable which has a runtime dependency on this target.

If this list contains linked npm packages, npm package store targets or other targets that provide JsInfo, NpmPackageStoreInfo providers are gathered from JsInfo. This is done directly from the npm_package_store_deps field of these. For linked npm package targets, the underlying npm_package_store target(s) that back the links is used.

Gathered NpmPackageStoreInfo providers are used downstream as direct dependencies when linking a downstream npm_package target with npm_link_package. | List of labels | optional | [] | -| define | A dict of global identifier replacements. Values are subject to $(location ...) expansion. Example:
python esbuild( name = "bundle", define = { "process.env.NODE_ENV": "production" }, ) 


See https://esbuild.github.io/api/#define for more details | Dictionary: String -> String | optional | {} | -| deps | A list of direct dependencies that are required to build the bundle | List of labels | optional | [] | -| entry_point | The bundle's entry point (e.g. your main.js or app.js or index.js)

This is a shortcut for the entry_points attribute with a single entry. Specify either this attribute or entry_point, but not both. | Label | optional | None | -| entry_points | The bundle's entry points (e.g. your main.js or app.js or index.js)

Specify either this attribute or entry_point, but not both. | List of labels | optional | [] | -| external | A list of module names that are treated as external and not included in the resulting bundle

See https://esbuild.github.io/api/#external for more details | List of strings | optional | [] | -| format | The output format of the bundle, defaults to iife when platform is browser and cjs when platform is node. If performing code splitting or multiple entry_points are specified, defaults to esm.

See https://esbuild.github.io/api/#format for more details | String | optional | "" | -| launcher | Override the default esbuild wrapper, which is supplied by the esbuild toolchain | Label | optional | None | -| max_threads | Sets the GOMAXPROCS variable to limit the number of threads that esbuild can run with. This can be useful if running many esbuild rule invocations in parallel, which has the potential to cause slowdown. For general use, leave this attribute unset. | Integer | optional | 0 | -| metafile | If true, esbuild creates a metafile along with the output | Boolean | optional | False | -| minify | Minifies the bundle with the built in minification. Removes whitespace, shortens identifieres and uses equivalent but shorter syntax.

Sets all --minify-* flags

See https://esbuild.github.io/api/#minify for more details | Boolean | optional | False | +| args_file | Internal use only | Label | optional | None | +| config | Configuration file used for esbuild. Note that options set in this file may get overwritten. TODO: show how to write a config file that depends on plugins, similar to the esbuild_config macro in rules_nodejs. | Label | optional | None | +| data | Runtime dependencies to include in binaries/tests that depend on this target.

The transitive npm dependencies, transitive sources, default outputs and runfiles of targets in the data attribute are added to the runfiles of this taregt. Thery should appear in the '*.runfiles' area of any executable which has a runtime dependency on this target.

If this list contains linked npm packages, npm package store targets or other targets that provide JsInfo, NpmPackageStoreInfo providers are gathered from JsInfo. This is done directly from the npm_package_store_deps field of these. For linked npm package targets, the underlying npm_package_store target(s) that back the links is used.

Gathered NpmPackageStoreInfo providers are used downstream as direct dependencies when linking a downstream npm_package target with npm_link_package. | List of labels | optional | [] | +| define | A dict of global identifier replacements. Values are subject to $(location ...) expansion. Example:
python esbuild( name = "bundle", define = { "process.env.NODE_ENV": "production" }, ) 


See https://esbuild.github.io/api/#define for more details | Dictionary: String -> String | optional | {} | +| deps | A list of direct dependencies that are required to build the bundle | List of labels | optional | [] | +| entry_point | The bundle's entry point (e.g. your main.js or app.js or index.js)

This is a shortcut for the entry_points attribute with a single entry. Specify either this attribute or entry_point, but not both. | Label | optional | None | +| entry_points | The bundle's entry points (e.g. your main.js or app.js or index.js)

Specify either this attribute or entry_point, but not both. | List of labels | optional | [] | +| external | A list of module names that are treated as external and not included in the resulting bundle

See https://esbuild.github.io/api/#external for more details | List of strings | optional | [] | +| format | The output format of the bundle, defaults to iife when platform is browser and cjs when platform is node. If performing code splitting or multiple entry_points are specified, defaults to esm.

See https://esbuild.github.io/api/#format for more details | String | optional | "" | +| launcher | Override the default esbuild wrapper, which is supplied by the esbuild toolchain | Label | optional | None | +| max_threads | Sets the GOMAXPROCS variable to limit the number of threads that esbuild can run with. This can be useful if running many esbuild rule invocations in parallel, which has the potential to cause slowdown. For general use, leave this attribute unset. | Integer | optional | 0 | +| metafile | If true, esbuild creates a metafile along with the output | Boolean | optional | False | +| minify | Minifies the bundle with the built in minification. Removes whitespace, shortens identifieres and uses equivalent but shorter syntax.

Sets all --minify-* flags

See https://esbuild.github.io/api/#minify for more details | Boolean | optional | False | | output | Name of the output file when bundling | Label | optional | | | output_css | Declare a .css file will be output next to output bundle.

If your JS code contains import statements that import .css files, esbuild will place the content in a file next to the main output file, which you'll need to declare. If your output file is named 'foo.js', you should set this to 'foo.css'. | Label | optional | | -| output_dir | If true, esbuild produces an output directory containing all output files | Boolean | optional | False | +| output_dir | If true, esbuild produces an output directory containing all output files | Boolean | optional | False | | output_map | Name of the output source map when bundling | Label | optional | | -| platform | The platform to bundle for.

See https://esbuild.github.io/api/#platform for more details | String | optional | "browser" | -| sourcemap | Defines where sourcemaps are output and how they are included in the bundle. By default, a separate .js.map file is generated and referenced by the bundle. If external, a separate .js.map file is generated but not referenced by the bundle. If inline, a sourcemap is generated and its contents are inlined into the bundle (and no external sourcemap file is created). If both, a sourcemap is inlined and a .js.map file is created.

See https://esbuild.github.io/api/#sourcemap for more details | String | optional | "" | -| sources_content | If False, omits the sourcesContent field from generated source maps

See https://esbuild.github.io/api/#sources-content for more details | Boolean | optional | False | -| splitting | If true, esbuild produces an output directory containing all the output files from code splitting for multiple entry points

See https://esbuild.github.io/api/#splitting and https://esbuild.github.io/api/#entry-points for more details | Boolean | optional | False | -| srcs | Source files to be made available to esbuild | List of labels | optional | [] | -| target | Environment target (e.g. es2017, chrome58, firefox57, safari11, edge16, node10, esnext). Default es2015.

See https://esbuild.github.io/api/#target for more details | String | optional | "es2015" | +| platform | The platform to bundle for.

See https://esbuild.github.io/api/#platform for more details | String | optional | "browser" | +| sourcemap | Defines where sourcemaps are output and how they are included in the bundle. By default, a separate .js.map file is generated and referenced by the bundle. If external, a separate .js.map file is generated but not referenced by the bundle. If inline, a sourcemap is generated and its contents are inlined into the bundle (and no external sourcemap file is created). If both, a sourcemap is inlined and a .js.map file is created.

See https://esbuild.github.io/api/#sourcemap for more details | String | optional | "" | +| sources_content | If False, omits the sourcesContent field from generated source maps

See https://esbuild.github.io/api/#sources-content for more details | Boolean | optional | False | +| splitting | If true, esbuild produces an output directory containing all the output files from code splitting for multiple entry points

See https://esbuild.github.io/api/#splitting and https://esbuild.github.io/api/#entry-points for more details | Boolean | optional | False | +| srcs | Source files to be made available to esbuild | List of labels | optional | [] | +| target | Environment target (e.g. es2017, chrome58, firefox57, safari11, edge16, node10, esnext). Default es2015.

See https://esbuild.github.io/api/#target for more details | String | optional | "es2015" | diff --git a/internal_deps.bzl b/internal_deps.bzl index 964117e..65937b3 100644 --- a/internal_deps.bzl +++ b/internal_deps.bzl @@ -46,9 +46,9 @@ def rules_esbuild_internal_deps(): maybe( http_archive, name = "io_bazel_stardoc", - sha256 = "05fb57bb4ad68a360470420a3b6f5317e4f722839abc5b17ec4ef8ed465aaa47", + sha256 = "3fd8fec4ddec3c670bd810904e2e33170bedfe12f90adf943508184be458c8bb", urls = [ - "https://mirror.bazel.build/github.com/bazelbuild/stardoc/releases/download/0.5.2/stardoc-0.5.2.tar.gz", - "https://github.com/bazelbuild/stardoc/releases/download/0.5.2/stardoc-0.5.2.tar.gz", + "https://mirror.bazel.build/github.com/bazelbuild/stardoc/releases/download/0.5.3/stardoc-0.5.3.tar.gz", + "https://github.com/bazelbuild/stardoc/releases/download/0.5.3/stardoc-0.5.3.tar.gz", ], )