Repository navigation
perf(build): inline component styles and slim the vendor chunk - #500
Merged
Merged
Conversation
The vendor-shared group also split the server build, which left an unresolved chunk placeholder in Nuxt 4.6's inline-style chunks. Inline styles were switched off to get past it, so pages linked up to nine render-blocking stylesheets. The group now applies to the client build only. It also captured comark-content's ContentRenderer, which pulled every content component and zod into the chunk every page preloads.
/cli imports developer-setup for one snippet, and the /developers query parsers there brought zod into every /cli load.
Collaborator
Author
|
Agent check (Claude Code, Harlan Agent Kit), since CI cannot cover it:
|
Contributor
🤖 MERGED
GitHub merged this pull request.
6e6d9d68-bc83-43c0-9a1e-4231cf205093 Selected findings run after merge and open separate pull requests. |
Contributor
There was a problem hiding this comment.
Harlan Agent Kit posted this automated review. AI open source policy.
Automated Review: READY.
1 of 6 tasks
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
Related to #467
❓ Type of change
📚 Description
Launch pages linked up to nine render-blocking stylesheets, and every page preloaded zod and the content components it never renders.
inlineStyles: falsebecause the Nuxt 4.6 server build left an unresolved chunk placeholder (!~{002}~) in its inline-style chunks. Thevendor-sharedgroup caused it: it split the server build too. The group now applies to the client build only, so Nuxt's default inlines component CSS again.vendor-shared. A group takes a module's static imports with it.ContentRendererimports every content component, so the Skill card, the package setup form and zod rode in the chunk every page preloads. The rule also matches Nuxt'scomark-content%2Fcomponents.mjstemplate./clino longer loads zod. It importsdeveloper-setup.tsfor one snippet. The/developersquery parsers there now live indeveloper-setup-query.ts.Measured on local
pnpm buildoutput served bywrangler dev, againstorigin/mainat 00cb19d. Lighthouse 13.5, mobile, cold cache, median of 3 runs.//skills/demos/skills/trending/gh/anthropics/skills/frontend-design/cli/developersThe trade: each page now preloads 6 to 9 more small files, because the Skill card and its parts get their own chunks instead of riding in
vendor-shared. Crawl efficiency counts files as a crawl cost, so this gives some of that back for 26 to 32 kB less gzip on five of the six pages.The homepage and Skill page LCP did not move. The homepage LCP is the hero heading, and the Skill page LCP is the lazy full-page demo screenshot. Both need separate work.