react-phone-apps/.blueprint/modules/monorepo-setup.md
lanrtop a0929de768 chore: 初始化项目结构与蓝图
- 配置 pnpm workspace monorepo 基础结构
- 初始化 .blueprint/ 蓝图:6 个业务模块、21 张任务卡
- 目标:Z Fold 6 折叠屏不动产物品摸底统计 App(React Native + Expo)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-07 15:23:39 +09:00

41 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
id: monorepo-setup
name: Monorepo 工程配置
area: infrastructure
status: done
---
## 概述
pnpm workspace 单体仓库基础配置,涵盖包管理、构建脚本和 Node.js 引擎约束。所有 apps/* 和 packages/* 自动纳入 workspace。
## 任务卡
### ✅ 初始化 pnpm workspace
- status: done
- complexity: S
- files: package.json, pnpm-workspace.yaml
- acceptance: pnpm-workspace.yaml 正确声明 apps/* 和 packages/*,根 package.json 包含 dev/build/lint 脚本engines 约束 node>=18 pnpm>=8
### 💭 统一 TypeScript 基础配置
- status: concept
- complexity: S
- files: tsconfig.base.json
- acceptance: 根目录提供 tsconfig.base.json各子包通过 extends 继承,启用 strict 模式
### 💭 统一 ESLint / Prettier 配置
- status: concept
- complexity: S
- files: eslint.config.js, .prettierrc
- acceptance: 根目录提供共享 lint 规则,各子包可通过 overrides 扩展pnpm lint 从根目录一键运行
### 💭 构建工具链选型
- status: concept
- complexity: M
- files: packages/build-config/package.json, packages/build-config/vite.base.ts
- acceptance: 封装 Vite 基础配置到 packages/build-config各 app 通过 extends 引入,减少重复配置
## 决策记录
- 选择 pnpm workspace 而非 Turborepo/Nx初期项目规模小pnpm 原生 workspace 足够,避免引入额外工具链复杂度