perf(picturebooks): drop provenance from manifest entries (#99) - #100
Merged
Merged
Conversation
The picture-book manifest is fetched on first paint of home, library and the hub, and every entry carried the book's full provenance block (attribution line, per-illustration credits, licence note): 633 KB for 189 books. Nothing on those surfaces shows provenance; the reader, end page and credits page all load the per-book <slug>.json, which keeps the complete block. PictureBookMeta now omits provenance and bookAsStory takes the full book. Manifest: 633 KB → 67 KB. Signed-off-by: Devu Dilip <devu.dilip@gmail.com>
This was referenced Sep 16, 2026
Deploying sirigannada with
|
| Latest commit: |
3b221c3
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://370da12b.sirigannada.pages.dev |
| Branch Preview URL: | https://perf-picturebooks-manifest.sirigannada.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Linked issue
Closes #99 (
accepted).What changed and why
public/data/picturebooks/manifest.jsonis fetched on first paint of home, library and the picture-book hub. Each entry carried the book's fullprovenanceblock (attribution line, per-illustration credits, licence note, ~2.7 KB per book), so after #98 it was 633 KB for 189 books. Nothing on those surfaces shows provenance; the reader, the end page and/picturebooks/<slug>/creditsall load the per-book<slug>.json, which keeps the complete block unchanged.PictureBookMetanow omitsprovenance(type comment explains why); the builder drops it.bookAsStorytakes the fullPictureBook(its only caller, the reader, already had one).Verification
npm run data:picturebooks,npm run data:validate(189 books),npm run typecheck,npm test(673) all green;next buildgreen./picturebooks/101376-hasi-kasa-ona-kasa/creditsshows the full attribution line, source link, licence and seven illustration credits; no console errors; manifest transfer measured at 66,558 bytes.Note for installed PWAs
/data/**is served cache-first andDATA_CACHEhas not been bumped since v5, so installed clients keep whatever manifest they cached and will not see this (or the 154 new books from #98) until the data cache is refreshed. Separate issue to follow.