@jahanxu/trellis 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +235 -0
- package/README.md +212 -0
- package/bin/trellis.js +3 -0
- package/dist/cli/index.d.ts +3 -0
- package/dist/cli/index.d.ts.map +1 -0
- package/dist/cli/index.js +97 -0
- package/dist/cli/index.js.map +1 -0
- package/dist/commands/init.d.ts +21 -0
- package/dist/commands/init.d.ts.map +1 -0
- package/dist/commands/init.js +527 -0
- package/dist/commands/init.js.map +1 -0
- package/dist/commands/update.d.ts +27 -0
- package/dist/commands/update.d.ts.map +1 -0
- package/dist/commands/update.js +1289 -0
- package/dist/commands/update.js.map +1 -0
- package/dist/configurators/antigravity.d.ts +8 -0
- package/dist/configurators/antigravity.d.ts.map +1 -0
- package/dist/configurators/antigravity.js +18 -0
- package/dist/configurators/antigravity.js.map +1 -0
- package/dist/configurators/claude.d.ts +32 -0
- package/dist/configurators/claude.d.ts.map +1 -0
- package/dist/configurators/claude.js +98 -0
- package/dist/configurators/claude.js.map +1 -0
- package/dist/configurators/codex.d.ts +8 -0
- package/dist/configurators/codex.d.ts.map +1 -0
- package/dist/configurators/codex.js +20 -0
- package/dist/configurators/codex.js.map +1 -0
- package/dist/configurators/cursor.d.ts +5 -0
- package/dist/configurators/cursor.d.ts.map +1 -0
- package/dist/configurators/cursor.js +52 -0
- package/dist/configurators/cursor.js.map +1 -0
- package/dist/configurators/gemini.d.ts +8 -0
- package/dist/configurators/gemini.d.ts.map +1 -0
- package/dist/configurators/gemini.js +52 -0
- package/dist/configurators/gemini.js.map +1 -0
- package/dist/configurators/iflow.d.ts +33 -0
- package/dist/configurators/iflow.d.ts.map +1 -0
- package/dist/configurators/iflow.js +99 -0
- package/dist/configurators/iflow.js.map +1 -0
- package/dist/configurators/index.d.ts +55 -0
- package/dist/configurators/index.d.ts.map +1 -0
- package/dist/configurators/index.js +220 -0
- package/dist/configurators/index.js.map +1 -0
- package/dist/configurators/kilo.d.ts +8 -0
- package/dist/configurators/kilo.d.ts.map +1 -0
- package/dist/configurators/kilo.js +51 -0
- package/dist/configurators/kilo.js.map +1 -0
- package/dist/configurators/kiro.d.ts +8 -0
- package/dist/configurators/kiro.d.ts.map +1 -0
- package/dist/configurators/kiro.js +20 -0
- package/dist/configurators/kiro.js.map +1 -0
- package/dist/configurators/opencode.d.ts +32 -0
- package/dist/configurators/opencode.d.ts.map +1 -0
- package/dist/configurators/opencode.js +92 -0
- package/dist/configurators/opencode.js.map +1 -0
- package/dist/configurators/shared.d.ts +12 -0
- package/dist/configurators/shared.d.ts.map +1 -0
- package/dist/configurators/shared.js +21 -0
- package/dist/configurators/shared.js.map +1 -0
- package/dist/configurators/workflow.d.ts +28 -0
- package/dist/configurators/workflow.d.ts.map +1 -0
- package/dist/configurators/workflow.js +134 -0
- package/dist/configurators/workflow.js.map +1 -0
- package/dist/constants/paths.d.ts +68 -0
- package/dist/constants/paths.d.ts.map +1 -0
- package/dist/constants/paths.js +77 -0
- package/dist/constants/paths.js.map +1 -0
- package/dist/constants/version.d.ts +9 -0
- package/dist/constants/version.d.ts.map +1 -0
- package/dist/constants/version.js +15 -0
- package/dist/constants/version.js.map +1 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -0
- package/dist/migrations/index.d.ts +54 -0
- package/dist/migrations/index.d.ts.map +1 -0
- package/dist/migrations/index.js +160 -0
- package/dist/migrations/index.js.map +1 -0
- package/dist/migrations/manifests/0.1.9.json +30 -0
- package/dist/migrations/manifests/0.2.0.json +49 -0
- package/dist/migrations/manifests/0.2.12.json +9 -0
- package/dist/migrations/manifests/0.2.13.json +9 -0
- package/dist/migrations/manifests/0.2.14.json +175 -0
- package/dist/migrations/manifests/0.2.15.json +33 -0
- package/dist/migrations/manifests/0.3.0-beta.0.json +278 -0
- package/dist/migrations/manifests/0.3.0-beta.1.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.10.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.11.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.12.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.13.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.14.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.15.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.16.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.2.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.3.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.4.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.5.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.6.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.7.json +11 -0
- package/dist/migrations/manifests/0.3.0-beta.8.json +9 -0
- package/dist/migrations/manifests/0.3.0-beta.9.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.0.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.1.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.2.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.3.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.4.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.5.json +9 -0
- package/dist/migrations/manifests/0.3.0-rc.6.json +9 -0
- package/dist/migrations/manifests/0.3.0.json +11 -0
- package/dist/templates/antigravity/index.d.ts +12 -0
- package/dist/templates/antigravity/index.d.ts.map +1 -0
- package/dist/templates/antigravity/index.js +29 -0
- package/dist/templates/antigravity/index.js.map +1 -0
- package/dist/templates/claude/agents/check.md +122 -0
- package/dist/templates/claude/agents/debug.md +106 -0
- package/dist/templates/claude/agents/dispatch.md +214 -0
- package/dist/templates/claude/agents/implement.md +96 -0
- package/dist/templates/claude/agents/plan.md +396 -0
- package/dist/templates/claude/agents/research.md +120 -0
- package/dist/templates/claude/commands/trellis/before-backend-dev.md +13 -0
- package/dist/templates/claude/commands/trellis/before-frontend-dev.md +13 -0
- package/dist/templates/claude/commands/trellis/before-role-work.md +364 -0
- package/dist/templates/claude/commands/trellis/brainstorm.md +474 -0
- package/dist/templates/claude/commands/trellis/break-loop.md +125 -0
- package/dist/templates/claude/commands/trellis/check-backend.md +13 -0
- package/dist/templates/claude/commands/trellis/check-cross-layer.md +153 -0
- package/dist/templates/claude/commands/trellis/check-frontend.md +13 -0
- package/dist/templates/claude/commands/trellis/create-command.md +154 -0
- package/dist/templates/claude/commands/trellis/finish-work.md +153 -0
- package/dist/templates/claude/commands/trellis/handoff.md +445 -0
- package/dist/templates/claude/commands/trellis/integrate-skill.md +219 -0
- package/dist/templates/claude/commands/trellis/onboard.md +358 -0
- package/dist/templates/claude/commands/trellis/parallel.md +193 -0
- package/dist/templates/claude/commands/trellis/pick-task.md +515 -0
- package/dist/templates/claude/commands/trellis/record-session.md +62 -0
- package/dist/templates/claude/commands/trellis/start.md +373 -0
- package/dist/templates/claude/commands/trellis/update-spec.md +354 -0
- package/dist/templates/claude/hooks/inject-subagent-context.py +873 -0
- package/dist/templates/claude/hooks/ralph-loop.py +388 -0
- package/dist/templates/claude/hooks/session-start.py +200 -0
- package/dist/templates/claude/index.d.ts +54 -0
- package/dist/templates/claude/index.d.ts.map +1 -0
- package/dist/templates/claude/index.js +85 -0
- package/dist/templates/claude/index.js.map +1 -0
- package/dist/templates/claude/settings.json +41 -0
- package/dist/templates/codex/index.d.ts +18 -0
- package/dist/templates/codex/index.d.ts.map +1 -0
- package/dist/templates/codex/index.js +40 -0
- package/dist/templates/codex/index.js.map +1 -0
- package/dist/templates/codex/skills/before-backend-dev/SKILL.md +18 -0
- package/dist/templates/codex/skills/before-frontend-dev/SKILL.md +18 -0
- package/dist/templates/codex/skills/brainstorm/SKILL.md +479 -0
- package/dist/templates/codex/skills/break-loop/SKILL.md +130 -0
- package/dist/templates/codex/skills/check-backend/SKILL.md +18 -0
- package/dist/templates/codex/skills/check-cross-layer/SKILL.md +158 -0
- package/dist/templates/codex/skills/check-frontend/SKILL.md +18 -0
- package/dist/templates/codex/skills/create-command/SKILL.md +101 -0
- package/dist/templates/codex/skills/finish-work/SKILL.md +148 -0
- package/dist/templates/codex/skills/integrate-skill/SKILL.md +221 -0
- package/dist/templates/codex/skills/onboard/SKILL.md +363 -0
- package/dist/templates/codex/skills/record-session/SKILL.md +67 -0
- package/dist/templates/codex/skills/start/SKILL.md +330 -0
- package/dist/templates/codex/skills/update-spec/SKILL.md +335 -0
- package/dist/templates/cursor/commands/trellis-before-backend-dev.md +13 -0
- package/dist/templates/cursor/commands/trellis-before-frontend-dev.md +13 -0
- package/dist/templates/cursor/commands/trellis-brainstorm.md +474 -0
- package/dist/templates/cursor/commands/trellis-break-loop.md +107 -0
- package/dist/templates/cursor/commands/trellis-check-backend.md +13 -0
- package/dist/templates/cursor/commands/trellis-check-cross-layer.md +153 -0
- package/dist/templates/cursor/commands/trellis-check-frontend.md +13 -0
- package/dist/templates/cursor/commands/trellis-create-command.md +154 -0
- package/dist/templates/cursor/commands/trellis-finish-work.md +143 -0
- package/dist/templates/cursor/commands/trellis-integrate-skill.md +219 -0
- package/dist/templates/cursor/commands/trellis-onboard.md +358 -0
- package/dist/templates/cursor/commands/trellis-record-session.md +62 -0
- package/dist/templates/cursor/commands/trellis-start.md +366 -0
- package/dist/templates/cursor/commands/trellis-update-spec.md +354 -0
- package/dist/templates/cursor/index.d.ts +24 -0
- package/dist/templates/cursor/index.d.ts.map +1 -0
- package/dist/templates/cursor/index.js +44 -0
- package/dist/templates/cursor/index.js.map +1 -0
- package/dist/templates/extract.d.ts +166 -0
- package/dist/templates/extract.d.ts.map +1 -0
- package/dist/templates/extract.js +296 -0
- package/dist/templates/extract.js.map +1 -0
- package/dist/templates/gemini/commands/trellis/before-backend-dev.toml +17 -0
- package/dist/templates/gemini/commands/trellis/before-frontend-dev.toml +17 -0
- package/dist/templates/gemini/commands/trellis/brainstorm.toml +420 -0
- package/dist/templates/gemini/commands/trellis/break-loop.toml +129 -0
- package/dist/templates/gemini/commands/trellis/check-backend.toml +17 -0
- package/dist/templates/gemini/commands/trellis/check-cross-layer.toml +147 -0
- package/dist/templates/gemini/commands/trellis/check-frontend.toml +17 -0
- package/dist/templates/gemini/commands/trellis/create-command.toml +119 -0
- package/dist/templates/gemini/commands/trellis/finish-work.toml +133 -0
- package/dist/templates/gemini/commands/trellis/integrate-skill.toml +104 -0
- package/dist/templates/gemini/commands/trellis/onboard.toml +111 -0
- package/dist/templates/gemini/commands/trellis/record-session.toml +66 -0
- package/dist/templates/gemini/commands/trellis/start.toml +292 -0
- package/dist/templates/gemini/commands/trellis/update-spec.toml +132 -0
- package/dist/templates/gemini/index.d.ts +21 -0
- package/dist/templates/gemini/index.d.ts.map +1 -0
- package/dist/templates/gemini/index.js +44 -0
- package/dist/templates/gemini/index.js.map +1 -0
- package/dist/templates/iflow/agents/check.md +122 -0
- package/dist/templates/iflow/agents/debug.md +106 -0
- package/dist/templates/iflow/agents/dispatch.md +214 -0
- package/dist/templates/iflow/agents/implement.md +96 -0
- package/dist/templates/iflow/agents/plan.md +396 -0
- package/dist/templates/iflow/agents/research.md +120 -0
- package/dist/templates/iflow/commands/trellis/before-backend-dev.md +13 -0
- package/dist/templates/iflow/commands/trellis/before-frontend-dev.md +13 -0
- package/dist/templates/iflow/commands/trellis/brainstorm.md +474 -0
- package/dist/templates/iflow/commands/trellis/break-loop.md +125 -0
- package/dist/templates/iflow/commands/trellis/check-backend.md +13 -0
- package/dist/templates/iflow/commands/trellis/check-cross-layer.md +153 -0
- package/dist/templates/iflow/commands/trellis/check-frontend.md +13 -0
- package/dist/templates/iflow/commands/trellis/create-command.md +152 -0
- package/dist/templates/iflow/commands/trellis/finish-work.md +153 -0
- package/dist/templates/iflow/commands/trellis/integrate-skill.md +219 -0
- package/dist/templates/iflow/commands/trellis/onboard.md +358 -0
- package/dist/templates/iflow/commands/trellis/parallel.md +193 -0
- package/dist/templates/iflow/commands/trellis/record-session.md +62 -0
- package/dist/templates/iflow/commands/trellis/start.md +373 -0
- package/dist/templates/iflow/commands/trellis/update-spec.md +354 -0
- package/dist/templates/iflow/hooks/inject-subagent-context.py +788 -0
- package/dist/templates/iflow/hooks/ralph-loop.py +388 -0
- package/dist/templates/iflow/hooks/session-start.py +143 -0
- package/dist/templates/iflow/index.d.ts +54 -0
- package/dist/templates/iflow/index.d.ts.map +1 -0
- package/dist/templates/iflow/index.js +85 -0
- package/dist/templates/iflow/index.js.map +1 -0
- package/dist/templates/iflow/settings.json +40 -0
- package/dist/templates/kilo/commands/trellis/before-backend-dev.md +13 -0
- package/dist/templates/kilo/commands/trellis/before-frontend-dev.md +13 -0
- package/dist/templates/kilo/commands/trellis/brainstorm.md +474 -0
- package/dist/templates/kilo/commands/trellis/break-loop.md +125 -0
- package/dist/templates/kilo/commands/trellis/check-backend.md +13 -0
- package/dist/templates/kilo/commands/trellis/check-cross-layer.md +153 -0
- package/dist/templates/kilo/commands/trellis/check-frontend.md +13 -0
- package/dist/templates/kilo/commands/trellis/create-command.md +152 -0
- package/dist/templates/kilo/commands/trellis/finish-work.md +129 -0
- package/dist/templates/kilo/commands/trellis/integrate-skill.md +219 -0
- package/dist/templates/kilo/commands/trellis/onboard.md +358 -0
- package/dist/templates/kilo/commands/trellis/parallel.md +194 -0
- package/dist/templates/kilo/commands/trellis/record-session.md +62 -0
- package/dist/templates/kilo/commands/trellis/start.md +321 -0
- package/dist/templates/kilo/commands/trellis/update-spec.md +285 -0
- package/dist/templates/kilo/index.d.ts +16 -0
- package/dist/templates/kilo/index.d.ts.map +1 -0
- package/dist/templates/kilo/index.js +39 -0
- package/dist/templates/kilo/index.js.map +1 -0
- package/dist/templates/kiro/index.d.ts +18 -0
- package/dist/templates/kiro/index.d.ts.map +1 -0
- package/dist/templates/kiro/index.js +40 -0
- package/dist/templates/kiro/index.js.map +1 -0
- package/dist/templates/kiro/skills/before-backend-dev/SKILL.md +18 -0
- package/dist/templates/kiro/skills/before-frontend-dev/SKILL.md +18 -0
- package/dist/templates/kiro/skills/brainstorm/SKILL.md +479 -0
- package/dist/templates/kiro/skills/break-loop/SKILL.md +130 -0
- package/dist/templates/kiro/skills/check-backend/SKILL.md +18 -0
- package/dist/templates/kiro/skills/check-cross-layer/SKILL.md +158 -0
- package/dist/templates/kiro/skills/check-frontend/SKILL.md +18 -0
- package/dist/templates/kiro/skills/create-command/SKILL.md +101 -0
- package/dist/templates/kiro/skills/finish-work/SKILL.md +148 -0
- package/dist/templates/kiro/skills/integrate-skill/SKILL.md +221 -0
- package/dist/templates/kiro/skills/onboard/SKILL.md +363 -0
- package/dist/templates/kiro/skills/record-session/SKILL.md +67 -0
- package/dist/templates/kiro/skills/start/SKILL.md +330 -0
- package/dist/templates/kiro/skills/update-spec/SKILL.md +335 -0
- package/dist/templates/markdown/agents.md +18 -0
- package/dist/templates/markdown/gitignore.txt +12 -0
- package/dist/templates/markdown/index.d.ts +27 -0
- package/dist/templates/markdown/index.d.ts.map +1 -0
- package/dist/templates/markdown/index.js +52 -0
- package/dist/templates/markdown/index.js.map +1 -0
- package/dist/templates/markdown/spec/backend/database-guidelines.md.txt +51 -0
- package/dist/templates/markdown/spec/backend/directory-structure.md.txt +54 -0
- package/dist/templates/markdown/spec/backend/error-handling.md.txt +51 -0
- package/dist/templates/markdown/spec/backend/index.md +40 -0
- package/dist/templates/markdown/spec/backend/index.md.txt +38 -0
- package/dist/templates/markdown/spec/backend/logging-guidelines.md.txt +51 -0
- package/dist/templates/markdown/spec/backend/quality-guidelines.md.txt +51 -0
- package/dist/templates/markdown/spec/backend/script-conventions.md +467 -0
- package/dist/templates/markdown/spec/frontend/component-guidelines.md.txt +59 -0
- package/dist/templates/markdown/spec/frontend/directory-structure.md.txt +54 -0
- package/dist/templates/markdown/spec/frontend/hook-guidelines.md.txt +51 -0
- package/dist/templates/markdown/spec/frontend/index.md.txt +39 -0
- package/dist/templates/markdown/spec/frontend/quality-guidelines.md.txt +51 -0
- package/dist/templates/markdown/spec/frontend/state-management.md.txt +51 -0
- package/dist/templates/markdown/spec/frontend/type-safety.md.txt +51 -0
- package/dist/templates/markdown/spec/guides/code-reuse-thinking-guide.md +118 -0
- package/dist/templates/markdown/spec/guides/code-reuse-thinking-guide.md.txt +92 -0
- package/dist/templates/markdown/spec/guides/cross-layer-thinking-guide.md.txt +94 -0
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md +394 -0
- package/dist/templates/markdown/spec/guides/cross-platform-thinking-guide.md.txt +319 -0
- package/dist/templates/markdown/spec/guides/index.md.txt +79 -0
- package/dist/templates/markdown/workspace-index.md +123 -0
- package/dist/templates/markdown/worktree.yaml.txt +58 -0
- package/dist/templates/opencode/agents/check.md +146 -0
- package/dist/templates/opencode/agents/debug.md +129 -0
- package/dist/templates/opencode/agents/dispatch.md +223 -0
- package/dist/templates/opencode/agents/implement.md +120 -0
- package/dist/templates/opencode/agents/research.md +147 -0
- package/dist/templates/opencode/agents/trellis-plan.md +427 -0
- package/dist/templates/opencode/commands/trellis/before-backend-dev.md +13 -0
- package/dist/templates/opencode/commands/trellis/before-frontend-dev.md +13 -0
- package/dist/templates/opencode/commands/trellis/brainstorm.md +474 -0
- package/dist/templates/opencode/commands/trellis/break-loop.md +125 -0
- package/dist/templates/opencode/commands/trellis/check-backend.md +13 -0
- package/dist/templates/opencode/commands/trellis/check-cross-layer.md +153 -0
- package/dist/templates/opencode/commands/trellis/check-frontend.md +13 -0
- package/dist/templates/opencode/commands/trellis/create-command.md +154 -0
- package/dist/templates/opencode/commands/trellis/finish-work.md +144 -0
- package/dist/templates/opencode/commands/trellis/integrate-skill.md +219 -0
- package/dist/templates/opencode/commands/trellis/migrate-specs.md +0 -0
- package/dist/templates/opencode/commands/trellis/onboard.md +358 -0
- package/dist/templates/opencode/commands/trellis/parallel.md +194 -0
- package/dist/templates/opencode/commands/trellis/record-session.md +62 -0
- package/dist/templates/opencode/commands/trellis/start.md +338 -0
- package/dist/templates/opencode/commands/trellis/update-spec.md +354 -0
- package/dist/templates/opencode/lib/trellis-context.js +436 -0
- package/dist/templates/opencode/package.json +5 -0
- package/dist/templates/opencode/plugin/inject-subagent-context.js +538 -0
- package/dist/templates/opencode/plugin/session-start.js +192 -0
- package/dist/templates/trellis/VERSION +1 -0
- package/dist/templates/trellis/deliverables/README.md +51 -0
- package/dist/templates/trellis/gitignore.txt +29 -0
- package/dist/templates/trellis/index.d.ts +49 -0
- package/dist/templates/trellis/index.d.ts.map +1 -0
- package/dist/templates/trellis/index.js +92 -0
- package/dist/templates/trellis/index.js.map +1 -0
- package/dist/templates/trellis/paths.README.md +277 -0
- package/dist/templates/trellis/paths.yaml +41 -0
- package/dist/templates/trellis/pool/implementations.json +5 -0
- package/dist/templates/trellis/pool/prototypes.json +5 -0
- package/dist/templates/trellis/pool/requirements.json +5 -0
- package/dist/templates/trellis/scripts/__init__.py +5 -0
- package/dist/templates/trellis/scripts/add_session.py +391 -0
- package/dist/templates/trellis/scripts/common/__init__.py +80 -0
- package/dist/templates/trellis/scripts/common/cli_adapter.py +522 -0
- package/dist/templates/trellis/scripts/common/developer.py +189 -0
- package/dist/templates/trellis/scripts/common/git_context.py +383 -0
- package/dist/templates/trellis/scripts/common/paths.py +346 -0
- package/dist/templates/trellis/scripts/common/phase.py +253 -0
- package/dist/templates/trellis/scripts/common/project_paths.py +189 -0
- package/dist/templates/trellis/scripts/common/registry.py +365 -0
- package/dist/templates/trellis/scripts/common/task_queue.py +255 -0
- package/dist/templates/trellis/scripts/common/task_utils.py +177 -0
- package/dist/templates/trellis/scripts/common/worktree.py +218 -0
- package/dist/templates/trellis/scripts/create_bootstrap.py +290 -0
- package/dist/templates/trellis/scripts/get_context.py +16 -0
- package/dist/templates/trellis/scripts/get_developer.py +26 -0
- package/dist/templates/trellis/scripts/handoff_generator.py +380 -0
- package/dist/templates/trellis/scripts/init_developer.py +51 -0
- package/dist/templates/trellis/scripts/multi_agent/__init__.py +5 -0
- package/dist/templates/trellis/scripts/multi_agent/cleanup.py +403 -0
- package/dist/templates/trellis/scripts/multi_agent/create_pr.py +329 -0
- package/dist/templates/trellis/scripts/multi_agent/plan.py +233 -0
- package/dist/templates/trellis/scripts/multi_agent/start.py +461 -0
- package/dist/templates/trellis/scripts/multi_agent/status.py +817 -0
- package/dist/templates/trellis/scripts/pool.py +373 -0
- package/dist/templates/trellis/scripts/task.py +1162 -0
- package/dist/templates/trellis/scripts-shell-archive/add-session.sh +384 -0
- package/dist/templates/trellis/scripts-shell-archive/common/developer.sh +129 -0
- package/dist/templates/trellis/scripts-shell-archive/common/git-context.sh +263 -0
- package/dist/templates/trellis/scripts-shell-archive/common/paths.sh +208 -0
- package/dist/templates/trellis/scripts-shell-archive/common/phase.sh +150 -0
- package/dist/templates/trellis/scripts-shell-archive/common/registry.sh +247 -0
- package/dist/templates/trellis/scripts-shell-archive/common/task-queue.sh +142 -0
- package/dist/templates/trellis/scripts-shell-archive/common/task-utils.sh +151 -0
- package/dist/templates/trellis/scripts-shell-archive/common/worktree.sh +128 -0
- package/dist/templates/trellis/scripts-shell-archive/create-bootstrap.sh +299 -0
- package/dist/templates/trellis/scripts-shell-archive/get-context.sh +7 -0
- package/dist/templates/trellis/scripts-shell-archive/get-developer.sh +15 -0
- package/dist/templates/trellis/scripts-shell-archive/init-developer.sh +34 -0
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/cleanup.sh +396 -0
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/create-pr.sh +241 -0
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/plan.sh +207 -0
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/start.sh +317 -0
- package/dist/templates/trellis/scripts-shell-archive/multi-agent/status.sh +828 -0
- package/dist/templates/trellis/scripts-shell-archive/task.sh +1204 -0
- package/dist/templates/trellis/spec/roles/designer/index.md +243 -0
- package/dist/templates/trellis/spec/roles/designer/mock-data-standards.md +481 -0
- package/dist/templates/trellis/spec/roles/designer/prototype-guidelines.md +429 -0
- package/dist/templates/trellis/spec/roles/frontend-impl/api-integration.md +565 -0
- package/dist/templates/trellis/spec/roles/frontend-impl/index.md +321 -0
- package/dist/templates/trellis/spec/roles/frontend-impl/state-management.md +599 -0
- package/dist/templates/trellis/spec/roles/pm/index.md +112 -0
- package/dist/templates/trellis/spec/roles/pm/prd-template.md +124 -0
- package/dist/templates/trellis/tasks/.gitkeep +0 -0
- package/dist/templates/trellis/workflow.md +416 -0
- package/dist/templates/trellis/worktree.yaml +47 -0
- package/dist/types/ai-tools.d.ts +56 -0
- package/dist/types/ai-tools.d.ts.map +1 -0
- package/dist/types/ai-tools.js +103 -0
- package/dist/types/ai-tools.js.map +1 -0
- package/dist/types/migration.d.ts +86 -0
- package/dist/types/migration.d.ts.map +1 -0
- package/dist/types/migration.js +8 -0
- package/dist/types/migration.js.map +1 -0
- package/dist/utils/compare-versions.d.ts +12 -0
- package/dist/utils/compare-versions.d.ts.map +1 -0
- package/dist/utils/compare-versions.js +76 -0
- package/dist/utils/compare-versions.js.map +1 -0
- package/dist/utils/file-writer.d.ts +23 -0
- package/dist/utils/file-writer.d.ts.map +1 -0
- package/dist/utils/file-writer.js +140 -0
- package/dist/utils/file-writer.js.map +1 -0
- package/dist/utils/project-detector.d.ts +16 -0
- package/dist/utils/project-detector.d.ts.map +1 -0
- package/dist/utils/project-detector.js +186 -0
- package/dist/utils/project-detector.js.map +1 -0
- package/dist/utils/template-fetcher.d.ts +51 -0
- package/dist/utils/template-fetcher.d.ts.map +1 -0
- package/dist/utils/template-fetcher.js +174 -0
- package/dist/utils/template-fetcher.js.map +1 -0
- package/dist/utils/template-hash.d.ts +78 -0
- package/dist/utils/template-hash.d.ts.map +1 -0
- package/dist/utils/template-hash.js +233 -0
- package/dist/utils/template-hash.js.map +1 -0
- package/package.json +87 -0
|
@@ -0,0 +1,429 @@
|
|
|
1
|
+
# 原型代码开发指南
|
|
2
|
+
|
|
3
|
+
> Designer 角色创建可运行原型的详细指南
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 核心原则
|
|
8
|
+
|
|
9
|
+
原型代码的目标是:
|
|
10
|
+
1. **可运行** - Frontend 可以直接启动并看到效果
|
|
11
|
+
2. **易替换** - Mock 数据和 API 位置清晰,Frontend 可以快速替换
|
|
12
|
+
3. **接近真实** - 布局、交互、数据结构接近最终产品
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
## 原型结构规范
|
|
17
|
+
|
|
18
|
+
### 推荐目录结构
|
|
19
|
+
|
|
20
|
+
```
|
|
21
|
+
task-dir/
|
|
22
|
+
├── src/
|
|
23
|
+
│ ├── pages/ # 页面组件
|
|
24
|
+
│ │ └── LoginPage.tsx
|
|
25
|
+
│ ├── components/ # 复用组件
|
|
26
|
+
│ │ ├── LoginForm.tsx
|
|
27
|
+
│ │ └── SocialLoginButtons.tsx
|
|
28
|
+
│ ├── mocks/ # Mock数据(集中管理)
|
|
29
|
+
│ │ └── auth.mock.ts
|
|
30
|
+
│ └── types/ # TypeScript类型定义
|
|
31
|
+
│ └── user.ts
|
|
32
|
+
├── package.json
|
|
33
|
+
├── tsconfig.json
|
|
34
|
+
└── README.md # 原型说明文档
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
### 文件命名规范
|
|
38
|
+
|
|
39
|
+
- **组件文件**:大驼峰命名 `LoginForm.tsx`
|
|
40
|
+
- **Mock 文件**:`*.mock.ts` 或 `*.mock.tsx`
|
|
41
|
+
- **类型文件**:小驼峰或大驼峰 `user.ts` 或 `User.ts`
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## Mock 数据规范
|
|
46
|
+
|
|
47
|
+
### 1. 集中管理
|
|
48
|
+
|
|
49
|
+
**✅ 推荐**:所有 Mock 数据放在 `src/mocks/` 目录
|
|
50
|
+
|
|
51
|
+
```typescript
|
|
52
|
+
// src/mocks/auth.mock.ts
|
|
53
|
+
import type { User } from '../types/user';
|
|
54
|
+
|
|
55
|
+
export const mockUser: User = {
|
|
56
|
+
id: "mock-user-1",
|
|
57
|
+
name: "张三",
|
|
58
|
+
email: "zhangsan@example.com",
|
|
59
|
+
avatar: "https://via.placeholder.com/150",
|
|
60
|
+
createdAt: "2026-01-01T00:00:00Z"
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
export const mockUserList: User[] = [
|
|
64
|
+
mockUser,
|
|
65
|
+
{
|
|
66
|
+
id: "mock-user-2",
|
|
67
|
+
name: "李四",
|
|
68
|
+
email: "lisi@example.com",
|
|
69
|
+
avatar: "https://via.placeholder.com/150",
|
|
70
|
+
createdAt: "2026-01-02T00:00:00Z"
|
|
71
|
+
},
|
|
72
|
+
// ... 10-20 条数据,模拟真实场景
|
|
73
|
+
];
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
**❌ 避免**:在组件中硬编码 Mock 数据
|
|
77
|
+
|
|
78
|
+
```typescript
|
|
79
|
+
// ❌ 不推荐
|
|
80
|
+
const LoginPage = () => {
|
|
81
|
+
const [user, setUser] = useState({ name: "测试用户" });
|
|
82
|
+
// ...
|
|
83
|
+
};
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
### 2. 类型安全
|
|
87
|
+
|
|
88
|
+
所有 Mock 数据必须符合类型定义:
|
|
89
|
+
|
|
90
|
+
```typescript
|
|
91
|
+
// src/types/user.ts
|
|
92
|
+
export interface User {
|
|
93
|
+
id: string;
|
|
94
|
+
name: string;
|
|
95
|
+
email: string;
|
|
96
|
+
avatar?: string;
|
|
97
|
+
createdAt: string;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
// src/mocks/auth.mock.ts
|
|
101
|
+
import type { User } from '../types/user';
|
|
102
|
+
|
|
103
|
+
// ✅ TypeScript 会检查类型
|
|
104
|
+
export const mockUser: User = {
|
|
105
|
+
id: "1",
|
|
106
|
+
name: "张三",
|
|
107
|
+
email: "zhangsan@example.com",
|
|
108
|
+
createdAt: "2026-01-01T00:00:00Z"
|
|
109
|
+
};
|
|
110
|
+
```
|
|
111
|
+
|
|
112
|
+
### 3. 真实性原则
|
|
113
|
+
|
|
114
|
+
Mock 数据应该接近真实场景:
|
|
115
|
+
|
|
116
|
+
**✅ 推荐**:
|
|
117
|
+
```typescript
|
|
118
|
+
export const mockProductList = [
|
|
119
|
+
{
|
|
120
|
+
id: "prod-001",
|
|
121
|
+
name: "iPhone 15 Pro",
|
|
122
|
+
price: 7999,
|
|
123
|
+
stock: 50,
|
|
124
|
+
category: "电子产品",
|
|
125
|
+
tags: ["手机", "苹果", "5G"],
|
|
126
|
+
createdAt: "2026-01-15T10:30:00Z"
|
|
127
|
+
},
|
|
128
|
+
// ... 10-20 条,覆盖各种场景
|
|
129
|
+
];
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
**❌ 避免**:
|
|
133
|
+
```typescript
|
|
134
|
+
export const mockProductList = [
|
|
135
|
+
{ id: "1", name: "test", price: 100 }
|
|
136
|
+
];
|
|
137
|
+
```
|
|
138
|
+
|
|
139
|
+
---
|
|
140
|
+
|
|
141
|
+
## Mock API 规范
|
|
142
|
+
|
|
143
|
+
### 1. API 位置标注
|
|
144
|
+
|
|
145
|
+
使用清晰的 TODO 注释标注需要替换的位置:
|
|
146
|
+
|
|
147
|
+
```typescript
|
|
148
|
+
// ✅ 推荐格式
|
|
149
|
+
const handleLogin = async (email: string, password: string) => {
|
|
150
|
+
// TODO: [Frontend] 替换为真实API调用 POST /api/auth/login
|
|
151
|
+
return new Promise<User>((resolve) => {
|
|
152
|
+
setTimeout(() => resolve(mockUser), 1000);
|
|
153
|
+
});
|
|
154
|
+
};
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
**TODO 注释格式**:
|
|
158
|
+
- `[Frontend]` - 标明需要 Frontend 角色处理
|
|
159
|
+
- API 方法和路径 - `POST /api/auth/login`
|
|
160
|
+
- 文件位置 - 自动通过 grep 查找
|
|
161
|
+
|
|
162
|
+
### 2. API 响应模拟
|
|
163
|
+
|
|
164
|
+
Mock API 应该模拟真实 API 的行为:
|
|
165
|
+
|
|
166
|
+
```typescript
|
|
167
|
+
// ✅ 推荐:模拟延迟、成功/失败场景
|
|
168
|
+
const mockLoginAPI = async (email: string, password: string): Promise<User> => {
|
|
169
|
+
// TODO: [Frontend] 替换为真实API调用 POST /api/auth/login
|
|
170
|
+
return new Promise((resolve, reject) => {
|
|
171
|
+
setTimeout(() => {
|
|
172
|
+
// 模拟登录失败
|
|
173
|
+
if (email === "fail@example.com") {
|
|
174
|
+
reject(new Error("邮箱或密码错误"));
|
|
175
|
+
} else {
|
|
176
|
+
resolve(mockUser);
|
|
177
|
+
}
|
|
178
|
+
}, 1000); // 模拟网络延迟
|
|
179
|
+
});
|
|
180
|
+
};
|
|
181
|
+
```
|
|
182
|
+
|
|
183
|
+
### 3. 状态管理
|
|
184
|
+
|
|
185
|
+
简单的原型可以使用 React 内置状态:
|
|
186
|
+
|
|
187
|
+
```typescript
|
|
188
|
+
// ✅ 推荐:简单原型使用 useState
|
|
189
|
+
const LoginPage = () => {
|
|
190
|
+
const [user, setUser] = useState<User | null>(null);
|
|
191
|
+
const [loading, setLoading] = useState(false);
|
|
192
|
+
const [error, setError] = useState<string | null>(null);
|
|
193
|
+
|
|
194
|
+
const handleLogin = async (email: string, password: string) => {
|
|
195
|
+
setLoading(true);
|
|
196
|
+
setError(null);
|
|
197
|
+
try {
|
|
198
|
+
const user = await mockLoginAPI(email, password);
|
|
199
|
+
setUser(user);
|
|
200
|
+
} catch (err) {
|
|
201
|
+
setError(err.message);
|
|
202
|
+
} finally {
|
|
203
|
+
setLoading(false);
|
|
204
|
+
}
|
|
205
|
+
};
|
|
206
|
+
|
|
207
|
+
return (
|
|
208
|
+
// ... JSX
|
|
209
|
+
);
|
|
210
|
+
};
|
|
211
|
+
```
|
|
212
|
+
|
|
213
|
+
**注意**:复杂状态(全局用户状态、购物车等)在原型阶段可以简化,Frontend 会补充完整的状态管理方案。
|
|
214
|
+
|
|
215
|
+
---
|
|
216
|
+
|
|
217
|
+
## 组件设计规范
|
|
218
|
+
|
|
219
|
+
### 1. 组件拆分原则
|
|
220
|
+
|
|
221
|
+
**按功能拆分**:
|
|
222
|
+
```
|
|
223
|
+
LoginPage (页面组件)
|
|
224
|
+
├── LoginForm (表单逻辑)
|
|
225
|
+
│ ├── EmailInput (输入组件)
|
|
226
|
+
│ └── PasswordInput (输入组件)
|
|
227
|
+
└── SocialLoginButtons (第三方登录)
|
|
228
|
+
```
|
|
229
|
+
|
|
230
|
+
**拆分标准**:
|
|
231
|
+
- 单一职责:每个组件只负责一个功能
|
|
232
|
+
- 可复用性:通用组件(如 Button、Input)可以被多个页面使用
|
|
233
|
+
- 复杂度控制:组件文件不超过 200 行
|
|
234
|
+
|
|
235
|
+
### 2. Props 接口定义
|
|
236
|
+
|
|
237
|
+
使用 TypeScript 定义清晰的 Props 接口:
|
|
238
|
+
|
|
239
|
+
```typescript
|
|
240
|
+
interface LoginFormProps {
|
|
241
|
+
onSubmit: (email: string, password: string) => void;
|
|
242
|
+
loading?: boolean;
|
|
243
|
+
error?: string;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
const LoginForm: React.FC<LoginFormProps> = ({ onSubmit, loading, error }) => {
|
|
247
|
+
// ...
|
|
248
|
+
};
|
|
249
|
+
```
|
|
250
|
+
|
|
251
|
+
### 3. 组件命名规范
|
|
252
|
+
|
|
253
|
+
- 页面组件:`XxxPage.tsx` (如 `LoginPage.tsx`)
|
|
254
|
+
- 功能组件:`XxxForm.tsx`、`XxxList.tsx`
|
|
255
|
+
- UI 组件:`Button.tsx`、`Input.tsx`
|
|
256
|
+
|
|
257
|
+
---
|
|
258
|
+
|
|
259
|
+
## 样式规范
|
|
260
|
+
|
|
261
|
+
### 推荐技术栈
|
|
262
|
+
|
|
263
|
+
根据项目选择:
|
|
264
|
+
|
|
265
|
+
| 技术栈 | 适用场景 | 优点 |
|
|
266
|
+
|--------|---------|------|
|
|
267
|
+
| **Tailwind CSS** | 快速原型 | 无需写 CSS 文件,开发快 |
|
|
268
|
+
| **CSS Modules** | 组件隔离 | 样式作用域明确 |
|
|
269
|
+
| **Styled Components** | 复杂主题 | 动态样式、主题切换 |
|
|
270
|
+
|
|
271
|
+
### Tailwind CSS 示例
|
|
272
|
+
|
|
273
|
+
```tsx
|
|
274
|
+
// ✅ 推荐:使用 Tailwind
|
|
275
|
+
const LoginButton = () => (
|
|
276
|
+
<button className="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded">
|
|
277
|
+
登录
|
|
278
|
+
</button>
|
|
279
|
+
);
|
|
280
|
+
```
|
|
281
|
+
|
|
282
|
+
### 样式原则
|
|
283
|
+
|
|
284
|
+
1. **接近最终效果**:布局、颜色、字体应该接近 PRD 要求
|
|
285
|
+
2. **响应式可选**:根据 PRD 要求决定是否实现响应式
|
|
286
|
+
3. **细节可简化**:动画、过渡效果可以简化,在 HANDOFF 中说明预期效果
|
|
287
|
+
|
|
288
|
+
---
|
|
289
|
+
|
|
290
|
+
## 交互实现规范
|
|
291
|
+
|
|
292
|
+
### 必须实现的交互
|
|
293
|
+
|
|
294
|
+
- [ ] **表单输入**:所有输入框可以输入
|
|
295
|
+
- [ ] **按钮点击**:所有按钮有点击事件
|
|
296
|
+
- [ ] **链接跳转**:所有链接可以跳转(或模拟跳转)
|
|
297
|
+
- [ ] **加载状态**:提交表单时显示加载状态
|
|
298
|
+
- [ ] **错误提示**:模拟错误场景并显示错误信息
|
|
299
|
+
|
|
300
|
+
### 可以简化的交互
|
|
301
|
+
|
|
302
|
+
- **复杂动画**:可以用简单过渡替代
|
|
303
|
+
- **拖拽排序**:可以用点击上下移动替代
|
|
304
|
+
- **实时搜索**:可以用按钮触发搜索替代
|
|
305
|
+
|
|
306
|
+
### 交互示例
|
|
307
|
+
|
|
308
|
+
```tsx
|
|
309
|
+
const LoginPage = () => {
|
|
310
|
+
const [email, setEmail] = useState('');
|
|
311
|
+
const [password, setPassword] = useState('');
|
|
312
|
+
const [loading, setLoading] = useState(false);
|
|
313
|
+
const [error, setError] = useState<string | null>(null);
|
|
314
|
+
|
|
315
|
+
const handleSubmit = async (e: React.FormEvent) => {
|
|
316
|
+
e.preventDefault();
|
|
317
|
+
setLoading(true);
|
|
318
|
+
setError(null);
|
|
319
|
+
|
|
320
|
+
try {
|
|
321
|
+
await mockLoginAPI(email, password);
|
|
322
|
+
// 跳转到首页(原型阶段可以 alert 或 console.log)
|
|
323
|
+
alert('登录成功!');
|
|
324
|
+
} catch (err) {
|
|
325
|
+
setError('登录失败,请检查邮箱和密码');
|
|
326
|
+
} finally {
|
|
327
|
+
setLoading(false);
|
|
328
|
+
}
|
|
329
|
+
};
|
|
330
|
+
|
|
331
|
+
return (
|
|
332
|
+
<form onSubmit={handleSubmit}>
|
|
333
|
+
<input
|
|
334
|
+
type="email"
|
|
335
|
+
value={email}
|
|
336
|
+
onChange={(e) => setEmail(e.target.value)}
|
|
337
|
+
placeholder="邮箱"
|
|
338
|
+
disabled={loading}
|
|
339
|
+
/>
|
|
340
|
+
<input
|
|
341
|
+
type="password"
|
|
342
|
+
value={password}
|
|
343
|
+
onChange={(e) => setPassword(e.target.value)}
|
|
344
|
+
placeholder="密码"
|
|
345
|
+
disabled={loading}
|
|
346
|
+
/>
|
|
347
|
+
{error && <p className="text-red-500">{error}</p>}
|
|
348
|
+
<button type="submit" disabled={loading}>
|
|
349
|
+
{loading ? '登录中...' : '登录'}
|
|
350
|
+
</button>
|
|
351
|
+
</form>
|
|
352
|
+
);
|
|
353
|
+
};
|
|
354
|
+
```
|
|
355
|
+
|
|
356
|
+
---
|
|
357
|
+
|
|
358
|
+
## 原型文档要求
|
|
359
|
+
|
|
360
|
+
### README.md 必须包含
|
|
361
|
+
|
|
362
|
+
```markdown
|
|
363
|
+
# [功能名称] 原型
|
|
364
|
+
|
|
365
|
+
## 功能说明
|
|
366
|
+
简要描述此原型实现的功能
|
|
367
|
+
|
|
368
|
+
## 启动方式
|
|
369
|
+
\`\`\`bash
|
|
370
|
+
npm install
|
|
371
|
+
npm run dev
|
|
372
|
+
\`\`\`
|
|
373
|
+
|
|
374
|
+
## Mock 数据位置
|
|
375
|
+
- 用户数据:src/mocks/user.mock.ts
|
|
376
|
+
- 产品数据:src/mocks/product.mock.ts
|
|
377
|
+
|
|
378
|
+
## 需要 Frontend 补充的功能
|
|
379
|
+
1. 替换 Mock API 为真实 API(位置:src/pages/LoginPage.tsx:45)
|
|
380
|
+
2. 接入全局用户状态管理
|
|
381
|
+
3. 完善错误处理(网络超时、权限验证)
|
|
382
|
+
|
|
383
|
+
## 技术栈
|
|
384
|
+
- React 18
|
|
385
|
+
- TypeScript 5
|
|
386
|
+
- Tailwind CSS 3
|
|
387
|
+
- Vite 5
|
|
388
|
+
```
|
|
389
|
+
|
|
390
|
+
---
|
|
391
|
+
|
|
392
|
+
## 检查清单
|
|
393
|
+
|
|
394
|
+
在完成原型前,确保:
|
|
395
|
+
|
|
396
|
+
- [ ] 项目可以正常启动(`npm run dev` 无报错)
|
|
397
|
+
- [ ] 所有交互可以操作(按钮、输入框、链接)
|
|
398
|
+
- [ ] Mock 数据结构合理(符合类型定义)
|
|
399
|
+
- [ ] Mock API 位置已用 TODO 注释标注
|
|
400
|
+
- [ ] 组件命名语义化
|
|
401
|
+
- [ ] README.md 包含必要信息
|
|
402
|
+
- [ ] 已测试关键交互流程(登录、提交、错误处理)
|
|
403
|
+
|
|
404
|
+
---
|
|
405
|
+
|
|
406
|
+
## 常见问题
|
|
407
|
+
|
|
408
|
+
### Q: 原型需要实现所有 PRD 功能吗?
|
|
409
|
+
A: 实现**核心流程**即可。边缘场景可以用 TODO 注释标注,交给 Frontend 补充。
|
|
410
|
+
|
|
411
|
+
### Q: 原型需要完美像素级还原设计稿吗?
|
|
412
|
+
A: 不需要。布局结构正确、颜色接近即可。细节由 Frontend 优化。
|
|
413
|
+
|
|
414
|
+
### Q: 如何处理复杂状态管理(Redux/Zustand)?
|
|
415
|
+
A: 原型阶段可以简化为 `useState` 或 `useContext`。在 HANDOFF 中说明需要 Frontend 接入全局状态。
|
|
416
|
+
|
|
417
|
+
### Q: 原型需要写单元测试吗?
|
|
418
|
+
A: 不需要。测试由 Frontend 补充。
|
|
419
|
+
|
|
420
|
+
### Q: 原型需要处理所有错误场景吗?
|
|
421
|
+
A: 只需要处理**主要错误场景**(如登录失败、网络错误)。边缘场景交给 Frontend。
|
|
422
|
+
|
|
423
|
+
---
|
|
424
|
+
|
|
425
|
+
## 相关文档
|
|
426
|
+
|
|
427
|
+
- [Designer 工作规范](./index.md)
|
|
428
|
+
- [Mock 数据标准](./mock-data-standards.md)
|
|
429
|
+
- [前端组件规范](../frontend/component-guidelines.md)
|