This repository contains the website, documentation and changelog of the software Langfuse (https://langfuse.com).
pnpm dev- Start development server on localhost:3333pnpm build- Build the production versionpnpm start- Start production server on localhost:3333
pnpm run prebuild- Updates GitHub stars and generates contributor data (runs automatically before build)bash scripts/update_cookbook_docs.sh- Convert Jupyter notebooks to markdown (uses uv with inline dependencies)pnpm run link-check- Check for broken links in documentation
pnpm run analyze- Analyze bundle size using @next/bundle-analyzer
This is a Nextra-based documentation site for Langfuse built with Next.js. Key architectural components:
- Nextra (3.0.15) - Documentation framework built on Next.js
- Next.js (15.2.4) - React framework
- shadcn/ui - UI component library with semantic color tokens
- Tailwind CSS - Styling (always use semantic color tokens, never explicit colors)
- TypeScript - Type safety
- pnpm - Package manager (v9.5.0)
- MDX/Markdown Pages:
/pages/- All documentation content - Components:
/components/- React components including custom MDX components - Cookbook:
/cookbook/- Jupyter notebooks converted to markdown - Static Assets:
/public/- Images, icons, and other static files
components/- Reusable React componentspages/- All site pages (docs, blog, changelog, FAQ)cookbook/- Jupyter notebooks (Python/JS) that get converted to markdowncomponents-mdx/- MDX components used across pagesscripts/- Build and maintenance scriptslib/- Utility functions and configurations
- Jupyter Notebooks: Edit
.ipynbfiles in/cookbook/ - Conversion: Run
bash scripts/update_cookbook_docs.shto convert to markdown (uses uv automatically) - Location: Generated markdown files are placed in
/pages/guides/cookbook/ - Important: Never edit generated
.mdfiles directly - always edit the source notebooks
next.config.mjs- Next.js configuration with extensive redirectstheme.config.tsx- Nextra theme configurationcomponents.json- shadcn/ui configurationtailwind.config.js- Tailwind CSS configuration
- Use semantic color tokens from shadcn/ui, never explicit colors
- Components follow shadcn/ui patterns and conventions
- Responsive design with mobile-first approach
- Documentation:
/pages/docs/- Technical documentation - Blog:
/pages/blog/- Blog posts with MDX - Changelog:
/pages/changelog/- Product updates - Cookbook:
/pages/guides/cookbook/- Generated from Jupyter notebooks - FAQ:
/pages/faq/- Frequently asked questions
- Development server runs on port 3333 (not standard 3000)
- Requires Node.js 22
- Uses pnpm as package manager
- Auto-generates contributor data and GitHub stars before builds
- Extensive redirect configuration for URL management
- CSP headers configured for security in production