Files
gowebbuild/templates/tpl.gowebbuild.yaml
T
pk 49c88da564 Add config extends and entry point exclusion
Profiles may inherit from another config file (extends: <path>): the
first profile of the referenced file is merged underneath (scalars from
the overlay win, slices concatenate base-first and de-duplicate, chains
resolve recursively, cycles are detected).

esbuild.excludeEntryPoints removes merged entry points by glob (** spans
path separators, * stays within a segment), applied after path
resolution so patterns and entries match in the same shape.

Lets product editions/flavors (e.g. the wmd4x Range Trader Pro edition)
build only their own entry set on top of a shared, merge-clean base
config. Includes unit tests and template docs.
2026-10-11 15:58:56 +02:00

44 lines
1.3 KiB
YAML

# A profile may inherit from another config file: the first profile of the
# referenced file is merged underneath this one (slices concatenate base-first,
# scalars from this profile win when set). Chains resolve recursively.
# extends: ./.gowebbuild.base.yaml
- esbuild:
entryPoints:
- frontend/the-app.js
# Entry points matching any of these patterns are removed after the
# merge. ** spans path separators, * stays within one segment.
# excludeEntryPoints:
# - ./frontend/src/apps/experimental/**
outdir: ./frontend-dist
sourcemap: 1
format: 3
splitting: true
platform: 0
bundle: true
write: true
logLevel: 3
purgeBeforeBuild: false
watch:
paths:
- ./frontend/src
exclude: []
injectLiveReload: ./frontend-dist/index.html
# serve: # Uncomment and set a path to enable
# path: ""
# port: 8080
copy:
- src: ./frontend/index.html
dest: ./frontend-dist
# download:
# - url: https://example.com/some-file-or-asset.js
# dest: ./frontend/src/vendor/some-file-or-asset.js
# replace:
# - pattern: "*.go|*.js|*.html"
# search: "Something"
# replace: "This"
# link:
# from: ../../web/tp-elements
# to: ./frontend
# productionBuildOptions:
# cmdPostBuild: ""