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
build: duplicate entry ids are not detected by the build itself; the second page silently overwrites the first #81
Why it matters validate.mjs catches duplicate ids, so CI is safe, but npm run build alone does not. loadEntries keeps both entries and a Map keyed by id keeps the last body, so writeEntryPages writes dist/entry/<id>/index.html twice and the surviving page mixes one entry's metadata with the other's body. A contributor who previews with npm run build sees a plausible page and never learns there is a clash until CI fails, or worse, if someone deploys a local build.
Evidence
site/build.mjs:75-77 (loadEntries, bodies.set(id, …)), :472-474 (writeEntryPages); no uniqueness check in between.
Suggested approach
Track ids in a Set inside loadEntries and push duplicate id "<id>" (<file1>, <file2>) to errors, which already aborts the build. Add a unit test once the helper is exported (see the test-coverage issue).
Done when node site/build.mjs fails with a named error on a duplicate id.
Activity
Open issues sweep: validation types, incremental build, added dates, …
TMHSDigital commentedon Oct 22, 2026
Resolved by #124, merged to main in 1e1cfb8.