Repository navigation
fix: publish the size that applications actually pay - #11
Merged
Merged
Conversation
0.0.2 said 8.6 KB everywhere. That is what the library's own code weighs, not what an application grows by: Angular publishes libraries in partial compilation, and the linker expands directive definitions during the consuming build, which `npm run size` never sees. scripts/app-size.mjs builds the same app with and without the grid and subtracts: +10.37 KB gzipped for <masonry-grid> and [masonryGridItem], +10.57 KB with every directive and the provider. README, llms.txt, demo and CONTRIBUTING now say ~10.4 KB; DOCS.md gives all three numbers and keeps the library comparison in own-code units. Also bumps the library to 0.0.3 and renames the workspace package to masonry-angular-workspace, so two package.json files no longer share a name with different versions.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
The demo was a client-rendered Angular app, so the HTML served to anything that does not run JavaScript was an empty <app-root></app-root>. GPTBot, ClaudeBot, PerplexityBot and the search-time crawlers read the response and nothing more, so every page was blank to all of them. - outputMode: 'static' with a server entry prerenders all five routes at build time. Still a static deployment: no server, no serverless function. - The notes, config and code panels are hidden rather than removed by control flow, so the source listing ships in the HTML. Config controls also keep their values when switching panels. - The gallery moves from /gallery to /. A redirectTo route prerenders as a meta-refresh stub with no content or social tags, so the bare domain had no preview card. /gallery now 301s to / in vercel.json. - inject-meta.mjs patches every prerendered page and points canonical and og:url at that page instead of the home page. The origin rule moves to site-origin.mjs, shared with the new make-sitemap.mjs. - sitemap.xml is generated from the pages the build actually produced, and robots.txt names the AI crawlers explicitly and links the sitemap. - index.html gains SoftwareSourceCode structured data. - verify-prerender.mjs fails if a route is missing from the output or ships under 600 characters of text, and CI runs it on every pull request.
MeAkib
marked this pull request as ready for review
October 1, 2026 10:43
This branch was successfully 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.
0.0.2 said 8.6 KB everywhere. That is what the library's own code weighs, not what an application grows by: Angular publishes libraries in partial compilation, and the linker expands directive definitions during the consuming build, which
npm run sizenever sees.scripts/app-size.mjs builds the same app with and without the grid and subtracts: +10.37 KB gzipped for and [masonryGridItem], +10.57 KB with every directive and the provider. README, llms.txt, demo and CONTRIBUTING now say ~10.4 KB; DOCS.md gives all three numbers and keeps the library comparison in own-code units.
Also bumps the library to 0.0.3 and renames the workspace package to masonry-angular-workspace, so two package.json files no longer share a name with different versions.
What does this change?
How to see it
Checks
npm testpassesnpm run formatrun on the files I touchednpm run verify:compat, if I changed anything public (builds a real app on Angular 17–22)