Skip to content

47-Eagle/docs

Repository files navigation

πŸ¦… Eagle Omnichain Vault Documentation

Modern, elegant documentation for the next-generation omnichain DeFi vault powered by LayerZero.

Deploy to GitHub Pages Documentation Built with Docusaurus

🌟 Features

  • πŸ“± Mobile-Responsive: Perfect experience on all devices
  • πŸŒ™ Dark/Light Mode: Automatic theme switching with high contrast text
  • πŸ” Advanced Search: Find information quickly
  • 🌐 Multi-Chain Ready: Documentation for all supported networks
  • πŸ“Š Interactive Diagrams: Mermaid diagrams explaining complex concepts
  • ⚑ Fast Loading: Optimized for speed and performance
  • 🎨 Beautiful Design: Modern UI with Eagle branding

πŸš€ Quick Start

Prerequisites

  • Node.js 18 or higher
  • npm or yarn package manager

Local Development

# Clone the repository
git clone https://github.com/47-Eagle/docs.git
cd docs

# Install dependencies
npm install

# Start development server
npm run start

# Your documentation will be available at http://localhost:3000

Build for Production

# Build static files
npm run build

# Serve locally to test
npm run serve

πŸ“ Documentation Structure

docs/                           # Developer Documentation
β”œβ”€β”€ dev/                       # Getting Started for Developers
β”‚   β”œβ”€β”€ overview.md           # Project overview
β”‚   β”œβ”€β”€ quick-start.md        # 10-minute setup guide
β”‚   β”œβ”€β”€ architecture.md       # System architecture deep dive
β”‚   β”œβ”€β”€ deployment.md         # Deployment instructions
β”‚   β”œβ”€β”€ testing.md           # Testing strategies
β”‚   β”œβ”€β”€ security.md          # Security considerations
β”‚   └── vanity-addresses.md   # Vanity address generation
β”œβ”€β”€ concepts/                  # Core Concepts
β”‚   β”œβ”€β”€ layerzero-integration.md  # LayerZero integration
β”‚   β”œβ”€β”€ ovault-pattern.md        # OVault pattern explanation
β”‚   β”œβ”€β”€ dual-token-strategy.md   # Dual-token strategy
β”‚   └── cross-chain-flows.md     # Cross-chain operation flows
β”œβ”€β”€ contracts/                # Smart Contract Documentation
β”‚   β”œβ”€β”€ eagle-ovault.md       # Main vault contract
β”‚   β”œβ”€β”€ share-oft-adapter.md  # Share OFT adapter
β”‚   β”œβ”€β”€ ovault-composer.md    # OVault composer
β”‚   β”œβ”€β”€ asset-ofts.md        # Asset OFT contracts
β”‚   └── share-oft.md         # Share OFT contract
β”œβ”€β”€ api/                      # API Reference
β”‚   β”œβ”€β”€ overview.md          # API overview
β”‚   β”œβ”€β”€ vault-operations.md  # Vault operation APIs
β”‚   β”œβ”€β”€ cross-chain.md       # Cross-chain APIs
β”‚   └── hardhat-tasks.md     # Hardhat task reference
└── advanced/                 # Advanced Topics
    β”œβ”€β”€ gas-optimization.md   # Gas optimization techniques
    β”œβ”€β”€ monitoring.md        # Monitoring and analytics
    └── troubleshooting.md   # Common issues and solutions

docs/users/                    # User-Friendly Documentation
β”œβ”€β”€ index.mdx                # Welcome page for users
β”œβ”€β”€ charm-finance-integration.mdx  # 3D visualization
β”œβ”€β”€ vault-operations.md      # How to use the vault
β”œβ”€β”€ withdrawals-and-liquidity.md   # Withdrawals
└── user-faq.md              # Frequently asked questions

🎯 Documentation Philosophy

Developer-Focused

  • Comprehensive: Complete technical documentation
  • Code Examples: Real, working code snippets
  • Architecture Diagrams: Visual system explanations
  • Best Practices: Production-ready guidance

User-Friendly

  • Plain English: No unnecessary jargon
  • Step-by-Step: Clear, actionable instructions
  • Visual Aids: Diagrams and flowcharts
  • FAQ Section: Common questions answered

Accessibility First

  • High Contrast: Text optimized for readability
  • Screen Reader Compatible: Proper semantic HTML
  • Keyboard Navigation: Full keyboard accessibility
  • Mobile Optimized: Works perfectly on all devices

πŸ”§ Configuration

Docusaurus Configuration

The site is configured in docusaurus.config.ts with:

  • Eagle branding and colors
  • LayerZero and Uniswap external links
  • GitHub integration for editing
  • Mermaid diagram support
  • Custom CSS with Eagle theme

Navigation Structure

Organized into two main sections:

  • πŸ‘¨β€πŸ’» Developers: Technical documentation
  • πŸ‘€ Users: User-friendly guides

Custom Styling

  • Eagle purple primary color (#4f46e5)
  • High contrast text for accessibility
  • Modern design with subtle gradients
  • Dark mode optimized for developers

πŸš€ Deployment

Automatic Deployment

The documentation automatically deploys to GitHub Pages when you push to the main branch:

  1. GitHub Actions builds the site
  2. Generated files are pushed to gh-pages branch
  3. Site is available at https://47-Eagle.github.io/docs/

Manual Deployment

# Deploy to GitHub Pages
GIT_USER=<your-github-username> npm run deploy

🀝 Contributing

We welcome contributions to improve the documentation!

Quick Contributions

  • Typos: Fix directly via GitHub's edit button
  • Small Changes: Make PR with clear description
  • New Content: Follow existing structure and style

Major Changes

  1. Open Issue: Discuss significant changes first
  2. Fork Repository: Create your own copy
  3. Create Branch: Use descriptive branch name
  4. Make Changes: Follow style guide
  5. Test Locally: Ensure everything works
  6. Submit PR: Clear title and description

Style Guide

  • Headings: Use sentence case with emojis
  • Code Blocks: Always specify language
  • Links: Use descriptive link text
  • Diagrams: Use Mermaid for technical diagrams
  • Tone: Professional but friendly

πŸ“Š Analytics & Monitoring

Performance Tracking

  • Build Times: Monitored via GitHub Actions
  • Lighthouse Scores: Regular performance audits
  • Bundle Size: Optimized for fast loading

User Analytics (Optional)

Ready for Google Analytics integration:

// In docusaurus.config.ts
gtag: {
  trackingID: 'G-XXXXXXXXXX',
  anonymizeIP: true,
}

πŸ› οΈ Development Tools

Available Scripts

npm run start          # Start development server
npm run build          # Build for production  
npm run serve          # Serve production build
npm run clear          # Clear Docusaurus cache
npm run typecheck      # TypeScript type checking
npm run swizzle        # Customize Docusaurus components

Useful Commands

# Generate new documentation
npm run docusaurus docs:version 1.0.0

# Add translations
npm run write-translations

# Generate heading IDs
npm run write-heading-ids

πŸ” SEO Optimization

The documentation is optimized for search engines:

  • Meta Descriptions: Each page has descriptive meta tags
  • Structured Data: Schema.org markup for better indexing
  • Sitemap: Automatically generated sitemap.xml
  • Open Graph: Social media sharing optimization
  • Fast Loading: Optimized for Core Web Vitals

🌐 Internationalization

Ready for multiple languages:

// In docusaurus.config.ts
i18n: {
  defaultLocale: 'en',
  locales: ['en', 'es', 'fr', 'zh'], // Add languages as needed
}

πŸ“± Progressive Web App

The documentation works as a PWA:

  • Offline Support: Cache important pages
  • App-like Experience: Install on mobile devices
  • Fast Loading: Service worker caching
  • Push Notifications: (Optional) Update notifications

πŸ› Troubleshooting

Common Issues

Build Fails

# Clear cache and reinstall
npm run clear
rm -rf node_modules package-lock.json
npm install
npm run build

Styling Issues

# Check CSS compilation
npm run start
# Open browser dev tools to inspect styles

Link Errors

# Check for broken links
npm run build
# Look for broken link warnings in output

Getting Help

  • Documentation Issues: Open GitHub issue
  • Docusaurus Help: Check Docusaurus documentation
  • Technical Support: Contact the Eagle team

πŸ“œ License

This documentation is licensed under the MIT License. See the LICENSE file for details.

πŸ™ Acknowledgments

Built with amazing open-source projects:


πŸ“š Documentation for the future of omnichain DeFi! Built with ❀️ by the Eagle team.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors