Skip to content

build: write the webpack bundle to dist/ instead of public/ - #167

Merged
eizedev merged 2 commits into
mainfrom
fix/bundle-dist
Nov 22, 2026
Merged

eizedev merged 2 commits into
mainfrom
fix/bundle-dist

Conversation

@eizedev

@eizedev eizedev commented Nov 22, 2026

Copy link
Copy Markdown
Owner

Fixes #165

The webpack bundle folder public/ is the same folder as Public/ on macOS and Windows. The module split in #163 adds Public/. The bundle now goes to modules/<Module>/dist/, as in the PSU plugin's module template (eizedev/claude-plugins#89).

Changed:

  • build/webpack.base.cjs: output folder dist. The Pivot worker build inherits it.
  • build/Build-Module.ps1: copies the bundle from dist/.
  • .gitignore: dist/ instead of public/.
  • .github/workflows/ci.yml and the command in AGENTS.md: the PSScriptAnalyzer filter skips dist.
  • build/Measure-PowerShellSize.ps1: skips dist. tests/powershell/Growth.Tests.ps1 now checks that modules/M/dist is skipped next to a measured Public/.
  • AGENTS.md: says where webpack writes the bundle.

After pulling: delete an old modules/*/public/ folder once. It is no longer ignored, and on macOS and Windows it is the future Public/ folder.

Checks

  • Built ECharts, Perspective and Pivot from origin/main and from this branch: diff -r of the output folders shows no difference. The demo modules build too.
  • npm test: 160 passed, 5 skipped. Pester: 357 passed, 0 failed, 7 skipped. PSScriptAnalyzer as in CI: 0 findings.
  • Growth: all four guards ok. Numbers are unchanged before and after (Pivot.psm1 2,731 code lines, New-UDPivotReport 267; no PowerShell file changed size).
  • Browser tests not run locally: the documentation site builds its own bundle into docs/assets/charts/ and does not read a module's bundle folder. CI runs them.
  • Places checked: README, module READMEs, docs/ (development page included), CONTRIBUTING, AGENTS.md, CI workflows, .jscpd.json, the docs site webpack config, Pester and node tests.

What does not fit

The list of skipped folders (node_modules, dist, output) is written in three places: the CI filter, Measure-PowerShellSize.ps1 and the command in AGENTS.md. This change had to edit all three. I propose one place for it in a follow-up.

🤖 Generated with Claude Code

eizedev and others added 2 commits November 22, 2026 23:04
public/ and the Public/ folder of the module split (#163) are one folder on
macOS and Windows: .gitignore hid Public/*.ps1, Build-Module copied them as
bundle files, and the case-insensitive PSScriptAnalyzer filter in CI dropped
their findings. The bundle goes to dist/ now, as in the PSU plugin's module
template. The built module is unchanged.

Fixes #165

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@eizedev
eizedev merged commit 1d87b06 into main Nov 22, 2026
19 of 20 checks passed
@eizedev
eizedev deleted the fix/bundle-dist branch November 22, 2026 22:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

build: the bundle folder public/ collides with Public/ of the module split

1 participant