You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Stop bundling: ship dist/ as one file per module, CLI imports the library #205
priority: highNeeds attention soon — not blocking, but don't let it sitstatus: implementedBuilt and deployed, but not yet fully tested/verifiedtype: enhancementAn improvement to existing functionality without adding a new feature
The build bundles src/ with tsup. Under the fleet rule in CLDMV/.github#582, builds no longer bundle: they don't move code around, merge modules into one file, or duplicate code to fit a bundler.
Here bin/fix-headers.mjs (from src/cli.mjs) is a second bundle next to dist/index.mjs, so the CLI ships its own copy of the library.
What to change:
dist/ and bin/ mirror src/, one file per module, each minified in place with keepNames.
No tsup bundle, no splitting, no chunk-* files. The CLI imports the library from dist/ rather than carrying its own copy.
Check every new URL("./x", import.meta.url) and relative path for the new layout.
Keep the hand-written src/index.cjs shim as it is.
Reference: CLDMV/lib-sqlite-wasm scripts/build-js.mjs. Plain .mjs repos can use esbuild with bundle: false over src/**/*.mjs, as droidsock, git-embedded, jsonv and llm-translator already do through tsup's bundle: false.
priority: highNeeds attention soon — not blocking, but don't let it sitstatus: implementedBuilt and deployed, but not yet fully tested/verifiedtype: enhancementAn improvement to existing functionality without adding a new feature
Activity
fix: build dist/ one file per module instead of bundling
fix: build dist/ one file per module instead of bundling (#206)
cldmv-bot commentedon Nov 26, 2026
Marked
status: implemented— resolved by #206, merged intonext. This issue closes automatically when that work ships to the default branch.release: v2.5.1 - build dist/ one file per module instead of bundling