mirror of
https://github.com/better-auth/better-auth.git
synced 2026-10-19 11:24:57 -05:00
The discovery URL, and every endpoint taken from the discovery document, had to be a trusted origin, while assertEndpointResolvesPublic skips trusted origins. The DNS guard on the discovery path could therefore never fire, and multi-tenant deployments were pushed to allowlist the very issuers their tenants control. Align the discovery path with the manual-config path: publicly routable hosts are allowed without a trustedOrigins entry, so the resolution guard runs before the fetch. Non-public hosts still need trustedOrigins and now fail with discovery_private_host. discovery_untrusted_origin stays in the error code union, deprecated, but is no longer emitted. Fixes #10830 Fixes #10831
Website & Docs
The main website and documentation for better-auth.com
Quick Start
# install
pnpm install
# develop
pnpm dev
Open localhost:3000 to preview.
Stack
- Framework: Next.js 16 (App Router, Turbopack)
- Styling: Tailwind CSS 4
- Animation: Framer Motion
- Docs: Fumadocs
- Icons: Lucide React
- Fonts: Geist Sans & Geist Mono
Structure
├─ app/
│ ├─ page.tsx # Home — hero + sign-in demo
│ ├─ products/ # Products page
│ ├─ blog/ # Blog posts
│ └─ docs/[[...slug]]/ # Documentation (MDX)
│
├─ components/
│ ├─ landing/ # Marketing components
│ ├─ docs/ # Documentation components
│ ├─ ui/ # Shared primitives
│ └─ icons/ # Brand icons & logo
│
├─ content/ # MDX documentation files
│
├─ lib/
│ ├─ source.ts # Fumadocs content source
│ └─ utils.ts # Utilities
│
└─ public/
└─ branding/ # Logo assets (SVG + PNG)
Scripts
pnpm dev # Start dev server (Turbopack)
pnpm build # Production build
pnpm start # Serve production build
pnpm lint:fix # Lint & auto-fix with Biome