frontend-platform-architecture-review
Reviews cross-cutting frontend architecture decisions (module boundaries, rendering topology, technology adoption) against a rewrite-averse, evidence-grounded standard before they are approved, producing an ADR-quality verdict rather than a stylistic opinion.
Install
npx skills add https://github.com/VincentChuWaiChow/vanguard-frontier-agentic/tree/master/skills/frontend/frontend-platform-architecture-review
claude plugin marketplace add https://llmmart.ai/marketplace.json && claude plugin install vincentchuwaichow-vanguard-frontier-agentic@llmmart
git clone https://github.com/VincentChuWaiChow/vanguard-frontier-agentic.git
The skills CLI installs just this skill, for any of its supported agents. Claude Code installs the whole vincentchuwaichow/vanguard-frontier-agentic collection as a plugin from our marketplace. Git is the plain clone.
Skill manifest
Frontend Platform Architecture Review
Purpose
Review proposed or existing frontend architecture — module/package boundaries, monorepo topology, rendering-strategy choice, technology adoption — for duplication, migration safety, and cross-team consistency, without re-litigating implementation-level state-management, routing, API-contract, or SSR-mechanics detail in every response. This skill exists so those adjacent concerns stay out of scope and the review stays focused on the cross-cutting, org-level decision: should this architectural change be approved, and on what terms.
When to use
Use this skill when the user asks to:
- review a proposal to adopt a new frontend framework, library, or build tool,
- resolve two teams solving the same problem with different primitives (state management, routing, styling),
- redraw a monorepo/polyrepo module boundary or ownership line,
- review a rendering-strategy change (CSR to SSR, SSR to SSG/ISR/streaming/PPR),
- audit an existing codebase for architectural entropy before a scaling or hiring push.
Do not use this skill for:
- implementation-level state-management review — route to
state-management-decision-review, - routing/navigation-specific review — route to
routing-navigation-review, - API-contract or data-fetching review — route to
api-integration-contract-review, - SSR/hydration mechanics debugging — route to
ssr-hydration-streaming-diagnosis, - responsive/visual UI design review — that needs a design-system/visual skill, not architecture review.
Context7 Documentation Protocol
- Before evaluating any version-sensitive technical claim in the proposal (e.g., "Next.js Partial Prerendering lets us do X," "React 19 Suspense enables Y"), call
resolve-library-idfor the exact library, thenquery-docsagainst the repo's confirmed version — readpackage.jsonfirst to confirm the installed major version before trusting a claim about API availability. - Matched library IDs for this skill's default grounding: React is
/reactjs/react.dev, Next.js is/vercel/next.js. Resolve fresh for any other framework named in a proposal (Angular, Vue, SvelteKit, etc.) rather than assuming these two cover every case. - Never approve a version-sensitive technical claim without Context7 verification. If Context7 is unavailable, mark the claim
documentation-based — unverified this sessionin the verdict and require the proposer to confirm the claim before final approval. - Documentation proves what a framework supports; it does not prove the proposal's specific repo can adopt it safely. Pair every Context7-grounded capability claim with a repo-evidence check (actual installed version, actual existing patterns) before treating it as settled.
Lean operating rules
- First classify the proposal: new capability, migration of an existing capability, or boundary redraw. Do not evaluate a migration as if it were greenfield.
- Check for an existing in-repo equivalent before evaluating the proposal on its own terms. A proposal that duplicates a capability the repo already solves is a duplication defect regardless of how well-argued the new approach is.
- Require at least two alternatives with tradeoffs before treating a single-option proposal as reviewable. A proposal with no alternatives considered is not ready for an architecture verdict — send it back.
- Default against "rewrite" framing. If an incremental strangler-fig or boundary-first path exists, require it over a big-bang rewrite; do not accept "the codebase is too messy to migrate incrementally" without the proposer demonstrating why.
- Treat accessibility and security posture as first-class, blocking review criteria — not items to defer to a follow-up ticket. An architecture proposal silent on a11y/security is incomplete, not merely imperfect.
- Treat Core Web Vitals budget impact as mandatory for any rendering-strategy change; a proposal with no stated LCP/INP/CLS impact (lab or field) has not been evaluated for its primary tradeoff.
- Never fabricate a performance or vitals number without a stated measurement source; label estimates
inference, not measuredand require the proposer to supply lab or field data before final approval. - Never execute, build, or run application code as part of this review; this is a static-review skill (Read/Grep/Glob only) — verdicts are based on document, code, and config evidence, not live measurement you generate yourself.
- Flag any architecture proposal that stores secrets or tokens in client-reachable bundles or build-time-inlined env vars, allows postinstall scripts from unpinned/unaudited dependencies, or introduces a CSP-incompatible pattern (
unsafe-eval, dynamicFunction()) as a blocking finding, not a note — this cannot be approved-with-conditions into a later cleanup.
References
Load these only when needed:
- Review workflow and ADR output contract — use for the step-by-step review procedure, the approve/approve-with-conditions/reject decision tree, and the required ADR-format output shape.
- Rendering topology and cross-cutting budgets — load only when the proposal changes rendering strategy (CSR/SSR/SSG/ISR/streaming/PPR) or when Core Web Vitals, a11y, or security posture needs grounding against current framework/WCAG guidance.
Response minimum
Return, at minimum:
- the architectural change and files/modules/teams in scope,
- duplication check result (existing in-repo equivalent found or none),
- every version-sensitive claim labeled
Context7-verifiedordocumentation-based — unverified this session, - verdict (approve / approve-with-conditions / reject-with-reasoning) with the specific unresolved conditions if any,
- rollback or incremental-migration path referenced explicitly,
- open questions the review could not resolve from available evidence.
Files (vanguard-frontier-agentic)
-
references
-
rendering-topology-and-budgets.md 6.5 KB
# Rendering Topology and Cross-Cutting Budgets Use this reference only when the proposal changes rendering strategy (CSR → SSR, SSR → SSG/ISR/streaming/PPR) or when Core Web Vitals, accessibility, or security posture needs grounding against current framework and WCAG guidance. Do not load this for a pure module-boundary or dependency-adoption proposal that does not touch rendering. ## What people get wrong The naive story is: > We're moving from SSR to PPR/streaming, so this is purely a performance upgrade — it's strictly better. Wrong. A rendering-topology change is a cross-cutting change to caching, hydration timing, focus/reading order, and the bundle's client-reachable surface — not an isolated performance knob. Officially, Next.js describes Partial Prerendering as combining a static prerendered shell with dynamic content streamed in via Suspense boundaries at request time; React's Suspense mechanism decides what streams and when. That means every dynamic region introduces a new hydration/streaming boundary that a11y (focus management, live-region announcements) and security (what's in the static shell vs. what's fetched dynamically, and with what auth context) both have to account for. Treating it as "just faster" skips the review this skill exists to force. ## Officially grounded rendering-strategy shape (Context7-verified) - **Partial Prerendering (PPR)** — Next.js's glossary describes PPR as "a rendering optimization that combines prerendering and dynamic rendering in a single route. The static shell is served immediately while dynamic content streams in when ready." As of Next.js 16, PPR is enabled via `cacheComponents: true` in `next.config`, replacing the earlier `experimental_ppr` route-segment flag. Verify the repo's installed Next.js major before citing either mechanism — the config surface changed between versions. - **Static-shell-plus-streaming pattern** — implemented via a `<Suspense fallback={...}>` boundary wrapping the dynamic component; the fallback is prerendered as part of the static shell, and the wrapped component streams once its data resolves. Every such boundary is a place where the visible-but-not-yet-interactive gap (for a11y) and the deferred-fetch trust boundary (for security) both need explicit review. - **Component decomposition as the review's dependency, not its subject** — React's own "Thinking in React" guidance frames component splitting around separation of concerns ("a component should ideally only be concerned with one thing. If it ends up growing, it should be decomposed into smaller subcomponents"). This skill does not re-review component-level decomposition (that is `react-component-architecture-review`'s job); it uses this principle only to sanity-check that a proposed module/rendering boundary maps to a real separation of concerns rather than an arbitrary split. ## Non-negotiable design rules 1. **State the Core Web Vitals budget impact per route class, not per app.** LCP/INP/CLS impact differs by route (a marketing shell vs. an authenticated dashboard); a single app-wide estimate hides regressions in the routes that matter most. 2. **Separate lab data from field data explicitly.** Lab data (Lighthouse, local traces) proves a route *can* meet budget under controlled conditions; field data (CrUX, RUM) proves it *does* for real users. A proposal citing only lab numbers as evidence of production impact is incomplete. 3. **Every new streaming/hydration boundary must state its focus-management and live-region behavior.** Content that pops in after initial paint can silently move focus or fail to announce to assistive technology; this is not optional polish, it is the a11y consequence of the rendering choice. 4. **State what's in the static shell vs. fetched dynamically, and under what auth context.** A static shell is often cached and served without per-request auth; if a proposal moves user-specific or sensitive data into a cached shell to hit a performance target, that is a security defect, not a clever optimization. 6. **Treat framework version as load-bearing for every claim.** PPR's config surface, Suspense streaming semantics, and caching defaults have all changed across React and Next.js majors — a claim true for one major can be false or renamed in another. Confirm the installed version before citing a mechanism. ## Adversarial checklist Before approving a rendering-topology change, answer these: - What is the LCP/INP/CLS budget for the specific route(s) affected, and is it lab data, field data, or an unmeasured estimate? - Which regions of the page are in the static shell, and which stream in dynamically? - Is any user-specific or sensitive data present in the static shell (which may be cached/shared across requests)? - What happens to keyboard focus and screen-reader announcements when a streamed region resolves after initial paint? - What is the fallback/loading state, and does it meet the same a11y bar as the resolved content (not just visually, but semantically)? - Does the target framework version actually support the mechanism being proposed, confirmed via Context7 against the installed version — not assumed from general familiarity with the framework? - If this fails or partially fails in production, what is the rollback — a config flag, a route-level revert, or a full redeploy? If these cannot be answered, the review is not ready for a verdict — send it back with the specific gaps named. ## High-risk assumptions to kill - "Streaming is strictly additive — it can only make things faster, never worse." - "The static shell has no sensitive data because we didn't put user data there on purpose." - "PPR/ISR works the same way in this Next.js major as it did in the blog post I read." - "A11y is a component-level concern, so it's out of scope for a rendering-strategy review." - "We'll measure Core Web Vitals after launch" as a substitute for a stated budget before launch. Those are lazy assumptions. Each one has caused a real production regression in review histories this skill's design pattern is meant to catch. ## When to push back Push back if the proposal: - states a performance goal with no route-level budget or measurement plan, - moves rendering strategy without naming the resulting static/dynamic data split, - treats accessibility of streamed content as a follow-up ticket rather than part of the design, - cites a framework capability without the installed version being confirmed against Context7-verified docs, - offers no rollback mechanism narrower than a full redeploy. That is not "shipping faster." It is deferring the review to production incidents. -
workflow-and-output.md 5.4 KB
# Review Workflow and ADR Output Contract Use this reference for the step-by-step review procedure, the decision tree governing approve/approve-with-conditions/reject, and the required output shape. Load it for every review; it is the orchestration layer the other reference does not cover. ## What people get wrong The naive story is: > The proposer already explained why this is a good idea, so my job is to sanity-check their reasoning. Wrong. The proposer's framing is evidence, not a starting truth. A reviewer who only checks internal consistency of the proposal will approve a well-argued duplication, a well-argued rewrite, and a well-argued a11y-deferral, because those things can all be argued well. The job is to check the proposal against the repo's actual state and against enterprise standards the proposer did not necessarily consider — not to grade the proposal's own essay. ## Step-by-step workflow 1. **Classify the proposal.** New capability, migration of an existing capability, or boundary redraw. This determines which checks apply — a new capability has no prior art to compare against; a migration must justify the replacement of what exists; a boundary redraw must show who owns what after the change. 2. **Check for an existing in-repo equivalent.** Search the repo (Grep/Glob) for the capability the proposal claims to introduce. If one exists, the proposal must explicitly justify why the existing one cannot be extended — silence on this is a duplication defect. 3. **Verify every version-sensitive technical claim via Context7.** Resolve the library, confirm the repo's installed major version from `package.json` or lockfile, then query docs for that version. Label each claim `Context7-verified` or `documentation-based — unverified this session`. 4. **Require at least two alternatives considered with tradeoffs.** A single-option proposal is not ready for a verdict; send it back with this specific gap named rather than guessing at alternatives on the proposer's behalf. 5. **Require an incremental migration plan with a rollback path.** Reject "big bang" proposals by default. If the proposer argues incremental migration is infeasible, that argument itself needs evidence (e.g., tight coupling that genuinely cannot be strangled), not just assertion. 6. **Confirm a11y and security posture are explicitly addressed.** Not assumed, not deferred to "we'll handle it in implementation." A rendering or module-boundary change that affects focus order, hydration timing, or bundle boundaries has a11y and security surface area; the proposal must name it. 7. **Confirm Core Web Vitals budget impact is stated for any rendering-strategy change.** Lab or field data, or an explicit estimate labeled `inference, not measured` with a commitment to measure post-launch. Silence is not acceptable for a rendering change. 8. **Issue a verdict.** Approve, approve-with-conditions, or reject-with-reasoning, using the decision tree below. ## Decision tree - Proposal duplicates an existing capability → **reject** unless the proposer justifies why the existing one cannot be extended. - Proposal has no rollback path → **reject-with-conditions**, requiring one before re-review. - Proposal is framed as a rewrite but an incremental strangler-fig path plausibly exists → **reject the rewrite framing**; request an incremental plan, do not simply approve the rewrite because it is well-written. - A11y or security posture is unaddressed → **reject-with-conditions**; this is never waived even if the proposer considers it out of scope. - Rendering-strategy change with no stated Core Web Vitals impact → **reject-with-conditions**; require lab or field data, or an explicit measurement commitment. - None of the above triggers apply → **approve** or **approve-with-conditions** based on any remaining, narrower gaps (e.g., missing ownership documentation, unresolved naming collision). ## ADR-format output contract Every verdict must be returned in this shape: 1. **Context** — what is being proposed, which teams/modules are affected, why now. 2. **Decision recommendation** — approve / approve-with-conditions / reject-with-reasoning, stated plainly in the first line. 3. **Duplication check** — existing in-repo equivalent found (with file/module evidence) or none found, and the search performed. 4. **Alternatives considered** — the two or more options and their tradeoffs, as supplied by the proposer or explicitly flagged as missing. 5. **Version-sensitive claims** — each claim labeled `Context7-verified` (with the library/version queried) or `documentation-based — unverified this session`. 6. **Consequences** — what this decision commits the org to, including maintenance burden and the "third way to do X" cost if a competing capability now exists. 7. **Rollback / incremental migration plan** — the specific mechanism (feature flag, route-level cutover, strangler-fig boundary), or its absence flagged as a blocking condition. 8. **A11y and security posture** — explicit statement of impact and mitigation, or flagged as a blocking condition if silent. 9. **Core Web Vitals budget impact** — for rendering-strategy changes only; lab/field data or a labeled estimate with a measurement commitment. 10. **Unresolved conditions** — the specific, named items blocking full approval, if any. Do not compress this into prose paragraphs when the proposal is non-trivial; use the numbered shape so gaps are visible at a glance to the next reviewer.
-
-
metadata.json 1.5 KB
{ "id": "frontend-platform-architecture-review", "name": "Frontend Platform Architecture Review", "type": "skill", "provider": "frontend", "harnesses": [ "claude-code", "cursor", "codex", "gemini", "kiro", "other" ], "summary": "Reviews cross-cutting frontend architecture decisions (module boundaries, rendering topology, technology adoption) against a rewrite-averse, evidence-grounded standard before they are approved, using duplication checks, incremental-migration requirements, and Core Web Vitals/a11y/security gates loaded progressively and grounded via Context7 against the repo's confirmed framework versions.", "source_type": "original", "official_docs": [ "https://react.dev/learn/thinking-in-react", "https://nextjs.org/docs/app/building-your-application/routing", "https://web.dev/articles/vitals", "https://www.w3.org/WAI/WCAG22/quickref/" ], "security_notes": "Static-review-only skill: it reads and greps proposal documents, config, and source but never executes, builds, or runs application code. Flag any architecture proposal that stores secrets/tokens in client-reachable bundles or build-time-inlined env vars, allows postinstall scripts from unpinned/unaudited dependencies, or introduces a CSP-incompatible pattern (unsafe-eval, dynamic Function()) as a blocking finding, not a note.", "last_verified": "2026-07-02", "path": "skills/frontend/frontend-platform-architecture-review", "author": "github: VincentChuWaiChow", "version": "0.1.0" } -
SKILL.md 6.3 KB
--- name: frontend-platform-architecture-review description: Reviews cross-cutting frontend architecture decisions (module boundaries, rendering topology, technology adoption) against a rewrite-averse, evidence-grounded standard before they are approved, producing an ADR-quality verdict rather than a stylistic opinion. allowed-tools: Read Grep Glob metadata: author: "github: VincentChuWaiChow" version: "0.1.0" updated: "2026-07-02" category: architecture --- # Frontend Platform Architecture Review ## Purpose Review proposed or existing frontend architecture — module/package boundaries, monorepo topology, rendering-strategy choice, technology adoption — for duplication, migration safety, and cross-team consistency, without re-litigating implementation-level state-management, routing, API-contract, or SSR-mechanics detail in every response. This skill exists so those adjacent concerns stay out of scope and the review stays focused on the cross-cutting, org-level decision: should this architectural change be approved, and on what terms. ## When to use Use this skill when the user asks to: - review a proposal to adopt a new frontend framework, library, or build tool, - resolve two teams solving the same problem with different primitives (state management, routing, styling), - redraw a monorepo/polyrepo module boundary or ownership line, - review a rendering-strategy change (CSR to SSR, SSR to SSG/ISR/streaming/PPR), - audit an existing codebase for architectural entropy before a scaling or hiring push. Do not use this skill for: - implementation-level state-management review — route to `state-management-decision-review`, - routing/navigation-specific review — route to `routing-navigation-review`, - API-contract or data-fetching review — route to `api-integration-contract-review`, - SSR/hydration mechanics debugging — route to `ssr-hydration-streaming-diagnosis`, - responsive/visual UI design review — that needs a design-system/visual skill, not architecture review. ## Context7 Documentation Protocol - Before evaluating any version-sensitive technical claim in the proposal (e.g., "Next.js Partial Prerendering lets us do X," "React 19 Suspense enables Y"), call `resolve-library-id` for the exact library, then `query-docs` against the repo's confirmed version — read `package.json` first to confirm the installed major version before trusting a claim about API availability. - Matched library IDs for this skill's default grounding: React is `/reactjs/react.dev`, Next.js is `/vercel/next.js`. Resolve fresh for any other framework named in a proposal (Angular, Vue, SvelteKit, etc.) rather than assuming these two cover every case. - Never approve a version-sensitive technical claim without Context7 verification. If Context7 is unavailable, mark the claim `documentation-based — unverified this session` in the verdict and require the proposer to confirm the claim before final approval. - Documentation proves what a framework *supports*; it does not prove the proposal's specific repo can adopt it safely. Pair every Context7-grounded capability claim with a repo-evidence check (actual installed version, actual existing patterns) before treating it as settled. ## Lean operating rules - First classify the proposal: new capability, migration of an existing capability, or boundary redraw. Do not evaluate a migration as if it were greenfield. - Check for an existing in-repo equivalent before evaluating the proposal on its own terms. A proposal that duplicates a capability the repo already solves is a duplication defect regardless of how well-argued the new approach is. - Require at least two alternatives with tradeoffs before treating a single-option proposal as reviewable. A proposal with no alternatives considered is not ready for an architecture verdict — send it back. - Default against "rewrite" framing. If an incremental strangler-fig or boundary-first path exists, require it over a big-bang rewrite; do not accept "the codebase is too messy to migrate incrementally" without the proposer demonstrating why. - Treat accessibility and security posture as first-class, blocking review criteria — not items to defer to a follow-up ticket. An architecture proposal silent on a11y/security is incomplete, not merely imperfect. - Treat Core Web Vitals budget impact as mandatory for any rendering-strategy change; a proposal with no stated LCP/INP/CLS impact (lab or field) has not been evaluated for its primary tradeoff. - Never fabricate a performance or vitals number without a stated measurement source; label estimates `inference, not measured` and require the proposer to supply lab or field data before final approval. - Never execute, build, or run application code as part of this review; this is a static-review skill (Read/Grep/Glob only) — verdicts are based on document, code, and config evidence, not live measurement you generate yourself. - Flag any architecture proposal that stores secrets or tokens in client-reachable bundles or build-time-inlined env vars, allows postinstall scripts from unpinned/unaudited dependencies, or introduces a CSP-incompatible pattern (`unsafe-eval`, dynamic `Function()`) as a blocking finding, not a note — this cannot be approved-with-conditions into a later cleanup. ## References Load these only when needed: - [Review workflow and ADR output contract](references/workflow-and-output.md) — use for the step-by-step review procedure, the approve/approve-with-conditions/reject decision tree, and the required ADR-format output shape. - [Rendering topology and cross-cutting budgets](references/rendering-topology-and-budgets.md) — load only when the proposal changes rendering strategy (CSR/SSR/SSG/ISR/streaming/PPR) or when Core Web Vitals, a11y, or security posture needs grounding against current framework/WCAG guidance. ## Response minimum Return, at minimum: - the architectural change and files/modules/teams in scope, - duplication check result (existing in-repo equivalent found or none), - every version-sensitive claim labeled `Context7-verified` or `documentation-based — unverified this session`, - verdict (approve / approve-with-conditions / reject-with-reasoning) with the specific unresolved conditions if any, - rollback or incremental-migration path referenced explicitly, - open questions the review could not resolve from available evidence.
Comments (0)
Sign in to join the conversation.
Reviews (0)
No reviews yet.
No comments yet.