mirror of
https://github.com/supabase/supabase.git
synced 2026-12-06 08:29:01 +00:00
About 95% of the 404s served on supabase.com are App Router RSC prefetches (`?_rsc=`) that www `<Link>`s fire at paths another zone serves: `/docs`, `/dashboard`, `/library`, and the footer's `humans.txt`, `lawyers.txt` and `security.txt`. Next.js can't prefetch or client-navigate across multi-zone boundaries, so each prefetch 404s even though the link itself works. I turned every www link into another zone into a plain `<a>` and added a lint rule so new ones stay that way. **Changed:** - **Cross-zone links are plain anchors**: links that always leave www (literal `/docs`, `/dashboard` and `.txt` hrefs, absolute `https://supabase.com/dashboard` URLs, the `getDashboardCtaHref` CTAs) render `<a>`. Renderers whose href comes from data (nav, footer, plan and add-on CTAs, product cards) branch on `isCrossZoneHref`, which reads the zone list from `lib/rewrites.js`. In-zone links stay `<Link>` and keep prefetching. - **New literal links can't regress**: `www/no-cross-zone-link` errors on a `next/link` `<Link>` whose literal or template href points at another zone. It evaluates `lib/rewrites.js` as production, so `/docs` counts in every environment. - **Click tracking survives the full navigation**: `sign_in_button_clicked`, `start_project_button_clicked` and `www_pricing_plan_cta_clicked` now send with `keepalive`, like `sign_in_submitted` already did, so an immediate page load can't cancel them. The mobile nav Sign in and Start your project buttons used `legacyBehavior`, which never called their `onClick`: PostHog has no `Mobile Nav` location for either event in the last 30 days. Those clicks report from this PR on. - **Typecheck no longer crashes**: the functions page's default export inferred a type through `RealtimeLogs`'s unexported `Props`, which makes the native TypeScript compiler panic during `tsc --noEmit`. I exported `Props`. **Note:** the lint rule only sees literal hrefs. A new renderer whose href comes from data needs its own `isCrossZoneHref` branch, and review is the only check on that. ## To test `/docs` is only rewritten on production and absolute `https://supabase.com/...` links are cross-origin on a preview, so the preview proves the relative non-docs cases (`/dashboard*`, `/library`, the footer .txt files). `/docs/...` prefetches still appear on the preview because it has no docs rewrite. Tested on Vercel preview: - [x] Open `/` with the network tab filtered to `_rsc` and scroll to the footer: no requests for `/dashboard*`, `/library`, `/design-system`, `/kb`, `/evals`, `/humans.txt`, `/lawyers.txt` or `/.well-known/security.txt`, while in-zone ones such as `/pricing`, `/features` and `/blog` still appear - [x] Same check on `/pricing`, `/auth`, `/database`, `/storage`, `/realtime`, `/edge-functions`, `/blog` and a blog post: no `_rsc` requests to `/dashboard*`, `/library` or the footer .txt files - [x] Open the Developers dropdown on desktop and the mobile menu at 390px: no new `_rsc` requests to `/dashboard*` or `/library` - [x] Click header Docs, footer Humans.txt, the hero Start your project button and the pricing Free plan button: each lands where it did before (`/docs`, `/humans.txt` text, `https://supabase.com/dashboard/sign-up`, `https://supabase.com/dashboard/new?plan=free`). Signed out, the Free plan button lands on the dashboard sign-in with `plan=free&returnTo=%2Fnew` - [x] Click the hero Start your project button: the `/platform/telemetry/event` POST with `start_project_button_clicked` completes with a 2xx after the page starts navigating. 201 with the navigation held; on the real navigation the event still reached staging PostHog - [x] At 390px, open the mobile menu and click Sign in: a `/platform/telemetry/event` POST with `sign_in_button_clicked` and `buttonLocation: "Mobile Nav"` fires. Start your project in the same menu also sends `start_project_button_clicked` with `buttonLocation: "Mobile Nav"` - [ ] Signed in, load `/`: no `/dashboard/projects?_rsc=` request (not run: the preview origin has no signed-in session) - [x] Open the desktop Product dropdown and the Product section of the 390px mobile menu: Compute shows its Private Alpha badge and the other products show none (checks the master merge into `MenuItem`) After deploy, `/` and `/pricing` on supabase.com show no `_rsc` requests to `/docs*`, `/dashboard*` or `/library`. After a full day, the share of supabase.com 404s carrying `_rsc=` should drop from about 95% to under 10%, and `sign_in_button_clicked` and `start_project_button_clicked` should start showing a `Mobile Nav` location in PostHog. ## Linear - fixes GROWTH-1294
161 lines
5.1 KiB
TypeScript
161 lines
5.1 KiB
TypeScript
import type { GoPageInput } from 'marketing'
|
|
import Image from 'next/image'
|
|
import Link from 'next/link'
|
|
import { Button } from 'ui'
|
|
|
|
const page: GoPageInput = {
|
|
template: 'lead-gen',
|
|
slug: 'postgres-summit-2026/contest',
|
|
metadata: {
|
|
title: 'Win a MacBook Neo | Supabase at Postgres Summit US 2026',
|
|
description:
|
|
'Thanks for connecting with us at Postgres Summit US 2026. Try Supabase — Postgres with everything you need. Enter for a chance to win a MacBook Neo.',
|
|
},
|
|
hero: {
|
|
title: 'Win a MacBook Neo',
|
|
subtitle: 'Supabase at Postgres Summit US 2026',
|
|
description:
|
|
'Thanks for connecting with us at Postgres Summit US 2026. Try Supabase — Postgres with everything you need. Enter for a chance to win a MacBook Neo.',
|
|
image: {
|
|
src: '/images/landing-pages/sxsw-2026/macbook-neo.png',
|
|
alt: 'MacBook Neo in four colors',
|
|
width: 500,
|
|
height: 333,
|
|
},
|
|
ctas: [
|
|
{
|
|
label: 'Get started',
|
|
href: '#how-to-enter',
|
|
variant: 'primary',
|
|
},
|
|
],
|
|
},
|
|
sections: [
|
|
{
|
|
type: 'single-column',
|
|
title: 'Everything to know about Postgres Locks',
|
|
description: 'Conference Talk: Wednesday, September 30, 2026 4:00 PM EDT, Rossi Intermediate',
|
|
children: (
|
|
<div className="flex flex-col items-center gap-6">
|
|
<Image
|
|
src="/images/landing-pages/postgres-summit-NYC-2026/brian-brennglass.png"
|
|
alt="Brian Brennglass"
|
|
width={192}
|
|
height={192}
|
|
className="rounded-full object-cover aspect-square w-48 h-48"
|
|
/>
|
|
<div className="flex flex-col items-center gap-0">
|
|
<p className="text-foreground-light font-medium">Brian Brennglass</p>
|
|
<p className="text-foreground-lighter text-sm">Supabase</p>
|
|
</div>
|
|
<Button asChild size="medium">
|
|
<Link
|
|
href="https://postgresql.us/events/postgressummitus2026/schedule/session/2406-everything-to-know-about-postgres-locks/"
|
|
target="_blank"
|
|
rel="noopener noreferrer"
|
|
>
|
|
View session details
|
|
</Link>
|
|
</Button>
|
|
</div>
|
|
),
|
|
},
|
|
{
|
|
type: 'single-column',
|
|
id: 'how-to-enter',
|
|
title: 'How to enter',
|
|
children: (
|
|
<div className="flex flex-col items-center gap-6">
|
|
<ol className="flex flex-col gap-4 text-foreground-light text-lg list-decimal list-inside">
|
|
<li>Create a Supabase account and note the email address you used</li>
|
|
<li>Load data into a Supabase database</li>
|
|
<li>Fill out the entry form below</li>
|
|
<li>
|
|
Complete these steps by the contest deadline, Monday October 12, 2026 at 12:00 PM PDT
|
|
</li>
|
|
</ol>
|
|
<Button asChild size="medium">
|
|
<a href="https://supabase.com/dashboard">Create your account</a>
|
|
</Button>
|
|
<p className="text-xs text-foreground-lighter mt-4">
|
|
No purchase necessary. Void where prohibited.{' '}
|
|
<Link href="/go/contest-rules" className="underline">
|
|
Official rules
|
|
</Link>
|
|
.
|
|
</p>
|
|
</div>
|
|
),
|
|
},
|
|
{
|
|
type: 'form',
|
|
id: 'enter-contest',
|
|
title: 'Enter the contest',
|
|
description: 'Fill out the form below to complete your entry.',
|
|
fields: [
|
|
{
|
|
type: 'text',
|
|
name: 'first_name',
|
|
label: 'First Name',
|
|
placeholder: 'First Name',
|
|
required: true,
|
|
half: true,
|
|
},
|
|
{
|
|
type: 'text',
|
|
name: 'last_name',
|
|
label: 'Last Name',
|
|
placeholder: 'Last Name',
|
|
required: true,
|
|
half: true,
|
|
},
|
|
{
|
|
type: 'email',
|
|
name: 'email_address',
|
|
label: 'Email',
|
|
placeholder: 'Email address',
|
|
required: true,
|
|
},
|
|
{
|
|
type: 'text',
|
|
name: 'company_name',
|
|
label: 'Company',
|
|
placeholder: 'Company name',
|
|
required: true,
|
|
},
|
|
],
|
|
submitLabel: 'Enter contest',
|
|
successRedirect: '/go/postgres-summit-2026/contest/thank-you',
|
|
disclaimer:
|
|
'By submitting this form, I confirm that I have read and understood the [Privacy Policy](https://supabase.com/privacy) and the [Official Rules](/go/contest-rules).',
|
|
crm: {
|
|
hubspot: {
|
|
formGuid: '32a0223e-784e-43bb-bdba-5cb3e72f35bd',
|
|
fieldMap: {
|
|
first_name: 'firstname',
|
|
last_name: 'lastname',
|
|
email_address: 'email',
|
|
company_name: 'name',
|
|
},
|
|
consent:
|
|
'By submitting this form, I confirm that I have read and understood the Privacy Policy.',
|
|
},
|
|
customerio: {
|
|
event: 'event_attended',
|
|
profileMap: {
|
|
email_address: 'email',
|
|
first_name: 'first_name',
|
|
last_name: 'last_name',
|
|
company_name: 'company_name',
|
|
},
|
|
staticProperties: {
|
|
event_name: 'Postgres Summit US 2026',
|
|
},
|
|
},
|
|
},
|
|
},
|
|
],
|
|
}
|
|
|
|
export default page
|