mirror of
https://github.com/AppFlowy-IO/AppFlowy-Web.git
synced 2025-12-01 11:57:53 +08:00
1.9 KiB
1.9 KiB
Claude Code Guidelines for AppFlowy-Web-Premium
This document provides clear instructions for Claude Code when working with the AppFlowy-Web-Premium repository.
Project Overview
AppFlowy-Web-Premium is the premium web version of AppFlowy built with modern web technologies.
Backend Integration: The backend service is AppFlowy-Cloud-Premium. All API definitions are declared in the cloud repository under libs/client-api (Rust implementation). This web project must adhere to the client-api definitions.
Development Environment
Prerequisites
- Node.js with pnpm package manager
- Docker for containerized services
- TypeScript for type safety
Essential Commands
# Development
pnpm install # Install dependencies
pnpm run dev # Start development server
pnpm run build # Build for production
# Quality Assurance
npx tsc # TypeScript type checking
pnpm run lint # Code linting
pnpm test # Run unit tests
pnpm cypress run # Run end-to-end tests
Protocol Buffers Integration
The protobuf definitions must match those declared in the appflowy-cloud-premium repository.
npx pbjs <options> # Compile protobuf to JavaScript
npx pbts <options> # Generate TypeScript definitions
Development Guidelines
Mandatory Verification Steps
- Build verification: Always run
pnpm run buildto ensure successful compilation - Type checking: Run
npx tscto verify TypeScript compilation - Code consistency: Follow established patterns in the existing codebase
- API compliance: Ensure all implementations respect the client-api definitions from the cloud repository
Best Practices
- Maintain consistency with existing code patterns
- Verify protobuf definitions align with the backend
- Ask for clarification when implementation approach is uncertain
- Test thoroughly before considering work complete