mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-08 23:08:19 -05:00
3.6 KiB
3.6 KiB
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Project Overview
This is the Reth documentation website built with Vocs, a modern documentation framework. The site contains comprehensive documentation for Reth, the Ethereum execution client, including installation guides, CLI references, SDK documentation, and tutorials.
Repository Structure
docs/pages/: All documentation content in MDX formatcli/: Command-line interface documentation and referencesexex/: Execution Extensions (ExEx) guides and examplesinstallation/: Installation and setup guidesintroduction/: Introduction, benchmarks, and why-reth contentjsonrpc/: JSON-RPC API documentationrun/: Node running guides and configurationsdk/: SDK documentation and examples
docs/snippets/: Code examples and snippets used in documentationsidebar.ts: Navigation configurationvocs.config.ts: Vocs configuration file
Essential Commands
# Install dependencies
bun install
# Start development server
bun run dev
# Build for production
bun run build
# Preview production build
bun run preview
Development Workflow
Content Organization
- MDX Files: All content is written in MDX (Markdown + React components)
- Navigation: Update
sidebar.tswhen adding new pages - Code Examples: Place reusable code snippets in
docs/snippets/ - Assets: Place images and static assets in
docs/public/
Adding New Documentation
- Create new
.mdxfiles in appropriate subdirectories underdocs/pages/ - Update
sidebar.tsto include new pages in navigation - Use consistent heading structure and markdown formatting
- Reference code examples from
docs/snippets/when possible
Code Examples and Snippets
- Live Examples: Use the snippets system to include actual runnable code
- Rust Code: Include cargo project examples in
docs/snippets/sources/ - CLI Examples: Show actual command usage with expected outputs
Configuration
- Base Path: Site deploys to
/rethpath (configured invocs.config.ts) - Theme: Custom accent colors for light/dark themes
- Vite: Uses Vite as the underlying build tool
Content Guidelines
- Be Practical: Focus on actionable guides and real-world examples
- Code First: Show working code examples before explaining concepts
- Consistent Structure: Follow existing page structures for consistency
- Cross-References: Link between related pages and sections
- Keep Current: Ensure documentation matches latest Reth features
File Naming Conventions
- Use kebab-case for file and directory names
- Match URL structure to file structure
- Use descriptive names that reflect content purpose
Common Tasks
Adding a new CLI command documentation:
- Create
.mdxfile indocs/pages/cli/reth/ - Add to sidebar navigation
- Include usage examples and parameter descriptions
Adding a new guide:
- Create
.mdxfile in appropriate category - Update sidebar with new entry
- Include practical examples and next steps
Updating code examples:
- Modify files in
docs/snippets/sources/ - Ensure examples compile and run correctly
- Test that documentation references work properly
Development Notes
- This is a TypeScript/React project using Vocs framework
- Content is primarily MDX with some TypeScript configuration
- Focus on clear, practical documentation that helps users succeed with Reth
- Maintain consistency with existing documentation style and structure