Documentation
PlatPhorm News Layout
A production-ready, AI-first shared layout system for the PlatPhorm News network. Fully typed, i18n-ready, and designed for both humans and AI agents.
Getting Started
Clone this layout to quickly bootstrap a new PlatPhorm News site with all the standard features: i18n, theming, observability, accessibility, and more.
1. Clone via V0
# Use V0 to fork this layout
v0 clone layout.platphormnews.com
# Or reference it as a template
v0 new my-site --template=platphorm-layout2. Configure Your Site
// lib/config/site.ts
export const SITE_CONFIG = {
name: "My News Site",
shortName: "MyNews",
url: "https://mynews.platphormnews.com",
// ... customize as needed
};3. Add Your Content
Create pages in app/[locale]/ and they'll automatically inherit the layout shell, i18n, theming, and observability.
Architecture
The layout follows a layered architecture designed for DRY reusability:
| Layer | Path | Purpose |
|---|---|---|
| Config | lib/config/ | Site settings, feature flags, network topology |
| Types | lib/types/ | TypeScript interfaces for all contracts |
| Providers | components/providers/ | Network, Theme, Trace, Observability contexts |
| Layout | components/layout/ | TopBar, Footer, Drawer, LocaleSwitcher |
| A11y | components/a11y/ | Skip links, focus trap, accessibility utilities |
| i18n | i18n/, messages/ | Locale config, routing, 8 language dictionaries |
Feature Flags
All features can be toggled via environment variables or runtime config:
Dark/light/system mode switcher in top bar
Language dropdown supporting 8 locales
Collapsible search input in top bar
Hamburger menu with network publication links
User authentication dropdown menu
Vercel, v0, and GitHub deploy/clone buttons
Floating deploy button in bottom-right corner
Hidden menu activated by typing PH3AR or 5x theme toggle
Command palette with dev tools and network utilities
Developer debugging panel (dev/preview only)
Full observability with correlation IDs and breadcrumbs
Vercel Analytics integration
Vercel Speed Insights for performance monitoring
User journey tracking for debugging
Privacy-respecting browser fingerprint for session correlation
Instant search engine indexing via IndexNow protocol
LLM discovery files for AI systems
RSS 2.0 and Atom feed generation
XML sitemap generation for search engines
humans.txt file with team and technology credits
robots.txt with AI-friendly directives
Model Context Protocol configuration endpoint
PlatPhorm News network API integration
Integration with trace.platphormnews.com
Outbound webhook support for events
Integration with svg.platphormnews.com for icons and images
Redirect 404 pages to 404.platphormnews.com or games.platphormnews.com
API Reference
The layout exposes several API endpoints for discovery and integration:
/api/health/api/docs/api/indexnow/llms.txt/llms-full.txt/rss.xml/feed.xml/sitemap.xml/robots.txt/humans.txt/manifest.json/.well-known/security.txt