Repository navigation
Conversation
Opening a chat thread eagerly downloaded and parsed 198 static JS files (5,723 KB raw, 1,814 KB gzipped), including `@pierre/diffs`, the VS Code file icon catalog, the GitHub HTML sanitizer, and panels and dialogs that start closed. Startup alone also pulled 96 separate files with 70 small chunks under 5 KB. This splits those features behind on-demand imports and groups stable initial libraries in Vite/Rolldown without pulling lazy code into startup: - Decouple `@pierre/diffs` from initial chat load, queue custom theme registrations until Pierre loads, recover from failed imports, and gate highlighter warm-up on fenced code blocks. - Load the VS Code file icon manifest on demand with a same-size fallback icon and reconnect retry. - Load the GitHub HTML markdown renderer only for GitHub HTML documents, and keep Find in chat indexing lazy while keeping the Find bar input, focus capture, and Escape handling eager. - Lazy-load closed-by-default side panels, dialogs, the theme picker, and scheduled task timeline lines, preserving Escape cancellation while chunks load and reserving row height for schedule lines. - Group initial React, Effect, TanStack, UI, contracts, and shared startup code in `apps/web/vite.config.ts`. This cuts initial chat thread JS by 942 KB raw (300 KB gzipped, -16.5%) and 45% fewer files, and drops app startup from 96 files to 8 files (-29 KB gzipped).
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
…-web-chunks # Conflicts: # apps/web/src/components/ChatView.tsx
This branch was previously deployed
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.
Stacked on #1095.
Opening a chat thread eagerly downloaded and parsed 198 static JS files (5,723 KB raw, 1,814 KB gzipped), including
@pierre/diffs, the VS Code file icon catalog, the GitHub HTML sanitizer, and closed-by-default panels and dialogs. App startup alone also loaded 96 separate files with 70 small chunks under 5 KB.What changed
@pierre/diffs(447 KB) from chat startup, queued custom code theme registrations until Pierre loads, cleared rejected import promises so transient failures recover, and gated highlighter warm-up on fenced code blocks so prose-only chats skip loading it.onlineretry recovery.codeSplittinggroups inapps/web/vite.config.tsfor initial React, Effect, TanStack, UI, contracts, and shared startup modules.apps/web/src/components/ChatView.panels.browser.tsxto wait for the lazy Source Control panel body after clicking its tab, matching the existing waits in the same test.Before and after bundle size
Measured from production builds of
chore/perf-apps-performance-auditversus this branch by tracing the exact static JS import graph for each screen.Verification
vp fmt,vp lint, andvp run typecheck(14/14 packages)vp run --cache '@threadlines/web#test'(273 test files, 3,408 tests)vp run --cache '@threadlines/web#test:browser'(118 test files, 1,215 tests)vp run '@threadlines/web#build'