backend-developer

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Backend Developer Skill

后端开发者技能

Use this skill when working with backend code to ensure project conventions are followed.
在处理后端代码时使用此技能,以确保遵循项目规范。

Loading Conventions

加载规范

CRITICAL: Before implementing any backend features, read ALL backend rules:
Step 1 - Techstack rules (required):
  1. Use Glob to find all files:
    .claude/rules/backend/*.md
  2. Read each file to load conventions
  3. Also read:
    .claude/rules/dataclasses/laravel-data.md
Step 2 - Project-specific rules (if exists):
  1. Check if
    .claude/project-rules/backend/
    directory exists
  2. If yes, use Glob to find all files:
    .claude/project-rules/backend/*.md
  3. Read each file to load project-specific patterns
These rules contain all patterns, conventions, and best practices for:
  • Controller structure and responsibilities
  • Data class creation and usage
  • Database and model patterns
  • PHP best practices
  • Testing conventions
  • Project-specific patterns (examples, boilerplate, etc.)
  • And more...
重要提示: 在实现任何后端功能之前,请阅读所有后端规则:
步骤1 - 技术栈规则(必填):
  1. 使用Glob查找所有文件:
    .claude/rules/backend/*.md
  2. 读取每个文件以加载规范
  3. 同时读取:
    .claude/rules/dataclasses/laravel-data.md
步骤2 - 项目特定规则(如果存在):
  1. 检查
    .claude/project-rules/backend/
    目录是否存在
  2. 如果存在,使用Glob查找所有文件:
    .claude/project-rules/backend/*.md
  3. 读取每个文件以加载项目特定模式
这些规则包含以下所有模式、规范和最佳实践:
  • 控制器结构与职责
  • 数据类的创建与使用
  • 数据库与模型模式
  • PHP最佳实践
  • 测试规范
  • 项目特定模式(示例、模板代码等)
  • 以及更多...

When to Use This Skill

何时使用此技能

Activate this skill when:
  • Implementing backend features (models, services, controllers)
  • Writing tests
  • Refactoring backend code
  • You need to verify backend patterns
  • User asks to "follow backend conventions"
  • You're in a different role but need backend context temporarily
在以下场景激活此技能:
  • 实现后端功能(模型、服务、控制器)
  • 编写测试
  • 重构后端代码
  • 需要验证后端模式
  • 用户要求“遵循后端规范”
  • 处于其他角色但暂时需要后端上下文

What This Skill Provides

此技能提供的内容

After loading the rules, you have complete context for:
  • When to create Data classes vs using arrays
  • How to structure controllers and services
  • Database and migration patterns
  • Testing approaches and factory usage
  • PHPDoc conventions
  • Type safety patterns
加载规则后,你将获得以下完整上下文:
  • 何时创建Data类而非使用数组
  • 如何构建控制器和服务
  • 数据库与迁移模式
  • 测试方法与工厂使用
  • PHPDoc规范
  • 类型安全模式

Integration with Other Skills

与其他技能的集成

This skill works alongside project-specific skills:
  • laravel-data-writer
    : For detailed Data class patterns
  • data-objects
    : For DataObject CRUD operations
  • object-definitions
    : For ObjectDefinition schema operations
  • multi-tenancy
    : For tenant isolation patterns
  • php-test-writer
    : For comprehensive test creation
此技能可与项目特定技能配合使用:
  • laravel-data-writer
    :用于详细的Data类模式
  • data-objects
    :用于DataObject的CRUD操作
  • object-definitions
    :用于ObjectDefinition的架构操作
  • multi-tenancy
    :用于租户隔离模式
  • php-test-writer
    :用于全面的测试创建

Key Principle

核心原则

Rules are the source of truth. This skill simply loads them and provides context on when to apply them.
The rules define:
  • WHAT the patterns are
  • HOW to implement them
  • WHAT to avoid
This skill provides:
  • WHEN to use which patterns
  • Context for applying rules in your current task
规则是唯一的事实来源。 此技能仅负责加载规则,并提供在何时应用它们的上下文。
规则定义了:
  • 模式是什么
  • 如何实现它们
  • 需要避免什么
此技能提供:
  • 何时使用哪种模式
  • 在当前任务中应用规则的上下文