Skip to content

perf: render pricing as server shell with client CTA islands#108

Merged
charlesrhoward merged 1 commit intomainfrom
codex/issue-99-pricing-server-shell
Feb 21, 2026
Merged

perf: render pricing as server shell with client CTA islands#108
charlesrhoward merged 1 commit intomainfrom
codex/issue-99-pricing-server-shell

Conversation

@charlesrhoward
Copy link
Contributor

@charlesrhoward charlesrhoward commented Feb 21, 2026

Summary\n- moved /pricing static content to a server component\n- extracted auth-aware CTA logic into small client components\n- replaced client FAQ state with native details/summary and kept canceled checkout notice as tiny client island\n\n## Validation\n- pnpm lint\n- pnpm build\n\nCloses #99


Note

Medium Risk
Touches pricing upgrade/downgrade UX and Stripe redirect flows (now moved into a new component), so regressions could affect conversions or subscription management, though the underlying API endpoints are unchanged.

Overview
Renders the /pricing page as a server component by removing client-only auth/queryparam state and the page-level Suspense loader, keeping interactivity in small client “islands”.

Extracts subscription CTA logic (login gating, Stripe checkout/portal redirects, loading states, and LoginDialog) into a reusable PricingPlanAction component for both Free/Pro cards, and moves the canceled-checkout queryparam notice into a tiny PricingCancelNotice client component rendered via Suspense.

Replaces FAQ open/close React state with native details/summary for simpler, more SSR-friendly behavior, and simplifies the Pro card background effect (removes mouse-following glow).

Written by Cursor Bugbot for commit a1ee4b9. This will update automatically on new commits. Configure here.

@charlesrhoward charlesrhoward enabled auto-merge (squash) February 21, 2026 21:35
@vercel
Copy link

vercel bot commented Feb 21, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
unicon Ready Ready Preview, Comment Feb 21, 2026 10:19pm

Request Review

Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 61301fd125

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

</span>
</button>
)}
<PricingPlanAction plan="pro" />

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Share auth state across plan action islands

Rendering PricingPlanAction for both cards means useAuth() runs twice on /pricing, and each instance performs supabase.auth.getUser() plus its own onAuthStateChange subscription and profile/subscription fetches. This introduces duplicated auth traffic and listeners for every page view (a regression from the previous single hook instance), which can delay CTA state resolution on slower clients; consider lifting auth state to one parent island and passing it down.

Useful? React with 👍 / 👎.

@charlesrhoward charlesrhoward force-pushed the codex/issue-99-pricing-server-shell branch from 27d030f to a1ee4b9 Compare February 21, 2026 22:17
@charlesrhoward charlesrhoward merged commit 6799648 into main Feb 21, 2026
7 checks passed
@charlesrhoward charlesrhoward deleted the codex/issue-99-pricing-server-shell branch February 21, 2026 22:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant