@donotdev/cli 0.0.12 → 0.0.13

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.
Files changed (67) hide show
  1. package/dependencies-matrix.json +30 -116
  2. package/dist/bin/commands/bump.js +33 -7
  3. package/dist/bin/commands/create-project.js +43 -7
  4. package/dist/bin/commands/deploy.js +7606 -17
  5. package/dist/bin/commands/firebase-setup.d.ts +6 -0
  6. package/dist/bin/commands/firebase-setup.d.ts.map +1 -0
  7. package/dist/bin/commands/firebase-setup.js +7 -0
  8. package/dist/bin/commands/firebase-setup.js.map +1 -0
  9. package/dist/bin/commands/staging.d.ts +11 -0
  10. package/dist/bin/commands/staging.d.ts.map +1 -0
  11. package/dist/bin/commands/staging.js +12 -0
  12. package/dist/bin/commands/staging.js.map +1 -0
  13. package/dist/bin/dndev.js +28 -3
  14. package/dist/bin/donotdev.js +28 -3
  15. package/dist/index.d.ts +1 -1
  16. package/dist/index.d.ts.map +1 -1
  17. package/dist/index.js +7671 -39
  18. package/dist/index.js.map +1 -1
  19. package/package.json +1 -1
  20. package/templates/app-demo/src/pages/DetailPage.tsx.example +1 -1
  21. package/templates/app-demo/src/pages/FullPage.tsx.example +3 -3
  22. package/templates/app-demo/src/pages/HomePage.tsx.example +1 -1
  23. package/templates/app-demo/src/pages/components/ComponentRenderer.tsx.example +5 -5
  24. package/templates/app-demo/src/pages/components/DemoLayout.tsx.example +3 -3
  25. package/templates/app-next/.env.example +2 -0
  26. package/templates/app-next/src/pages/HomePage.tsx.example +1 -1
  27. package/templates/app-vite/.env.example +2 -0
  28. package/templates/app-vite/src/pages/HomePage.tsx.example +163 -73
  29. package/templates/functions-firebase/build.mjs.example +26 -10
  30. package/templates/functions-firebase/functions-firebase/build.mjs.example +26 -10
  31. package/templates/functions-firebase/functions.config.js.example +11 -15
  32. package/templates/github-consumer/.github/workflows/ci.yml.example +36 -0
  33. package/templates/root-consumer/.claude/agents/architect.md.example +2 -2
  34. package/templates/root-consumer/.claude/agents/builder.md.example +2 -2
  35. package/templates/root-consumer/.claude/agents/coder.md.example +2 -2
  36. package/templates/root-consumer/.claude/agents/extractor.md.example +2 -3
  37. package/templates/root-consumer/.claude/agents/polisher.md.example +67 -291
  38. package/templates/root-consumer/.claude/agents/prompt-engineer.md.example +4 -4
  39. package/templates/root-consumer/.claude/commands/build.md.example +2 -2
  40. package/templates/root-consumer/.claude/commands/polish.md.example +65 -81
  41. package/templates/root-consumer/.env.example +13 -13
  42. package/templates/root-consumer/.gemini/settings.json.example +9 -0
  43. package/templates/root-consumer/.gitignore.example +3 -1
  44. package/templates/root-consumer/AI.md.example +139 -0
  45. package/templates/root-consumer/CLAUDE.md.example +13 -104
  46. package/templates/root-consumer/README.md.example +81 -255
  47. package/templates/root-consumer/entities/Contact.ts.example +126 -0
  48. package/templates/root-consumer/entities/index.ts.example +6 -3
  49. package/templates/root-consumer/guides/dndev/AGENT_START_HERE.md.example +41 -342
  50. package/templates/root-consumer/guides/dndev/COMPONENTS_ADV.md.example +2 -1
  51. package/templates/root-consumer/guides/dndev/ENV_SETUP.md.example +144 -9
  52. package/templates/root-consumer/guides/dndev/INDEX.md.example +9 -0
  53. package/templates/root-consumer/guides/dndev/SETUP_APP_CONFIG.md.example +13 -16
  54. package/templates/root-consumer/guides/dndev/SETUP_BLOG.md.example +263 -0
  55. package/templates/root-consumer/guides/dndev/SETUP_CRUD.md.example +1 -1
  56. package/templates/root-consumer/guides/dndev/SETUP_FIREBASE.md.example +168 -0
  57. package/templates/root-consumer/guides/dndev/SETUP_FUNCTIONS.md.example +5 -12
  58. package/templates/root-consumer/guides/dndev/SETUP_TESTING.md.example +184 -0
  59. package/templates/root-consumer/guides/wai-way/WAI_WAY_CLI.md.example +134 -69
  60. package/templates/root-consumer/guides/wai-way/agents/polisher.md.example +66 -44
  61. package/templates/root-consumer/guides/wai-way/blueprints/0_brainstorm.md.example +18 -1
  62. package/templates/root-consumer/guides/wai-way/blueprints/1_scaffold.md.example +1 -0
  63. package/templates/root-consumer/guides/wai-way/blueprints/2_entities.md.example +2 -1
  64. package/templates/root-consumer/guides/wai-way/blueprints/3_compose.md.example +2 -1
  65. package/templates/root-consumer/guides/wai-way/blueprints/4_configure.md.example +180 -108
  66. package/templates/root-consumer/guides/wai-way/context_map.json.example +8 -7
  67. package/templates/root-consumer/guides/wai-way/page_patterns.md.example +4 -4
@@ -15,13 +15,98 @@
15
15
 
16
16
  ---
17
17
 
18
+ ## The Intelligence Engine (MCP Server)
19
+
20
+ Your project is pre-configured with a **Knowledge Engine** (MCP Server) in `.mcp.json`.
21
+
22
+ 1. **Phase Tracking:** `start_phase(N)` returns the blueprint, agent persona, and files to read for each phase.
23
+ 2. **Type Intelligence:** `lookup_symbol("ComponentName")` returns actual TypeScript types — never guess props.
24
+ 3. **Knowledge Retrieval:** `get_guide("CRUD")`, `get_guideline("styling")`, `search_framework("keyword")`.
25
+ 4. **Implementation Tracking:** `init_implementation()` creates a persistent checklist. `update_progress()` ticks items. `get_progress()` reads status. Survives across sessions.
26
+ 5. **Captain's Log:** Session history auto-recorded on `approve_phase()`. `get_project_history()` for metrics and post-mortem.
27
+ 6. **Lessons:** `record_lesson("gotcha", { tags: ["stripe", "billing"] })` saves tagged gotchas to `.dndev/LESSONS.md`. Filtered by phase + module on next `start_phase`.
28
+
29
+ The IDE (Cursor, Claude Code, etc.) handles file write approval natively. No MCP-level gating.
30
+
31
+ ---
32
+
33
+ ## Implementation Tracking (Multi-Session Progress)
34
+
35
+ For projects that span multiple AI sessions, `.dndev/implementation.md` tracks what's done and what's pending.
36
+
37
+ ### Setup (after Phase 0)
38
+
39
+ ```
40
+ # Auto-generate from spec
41
+ init_implementation({ from_spec: true })
42
+
43
+ # Or manual sections
44
+ init_implementation({ sections: [
45
+ { title: "Auth Module", items: ["Login page", "Registration", "Password reset"] },
46
+ { title: "Dashboard", items: ["Stats cards", "Activity feed", "Charts"] }
47
+ ] })
48
+ ```
49
+
50
+ ### During Work
51
+
52
+ ```
53
+ # Tick items as you complete them
54
+ update_progress({ item: "Login page", done: true })
55
+ update_progress({ item: "Stats cards", done: true, note: "Used Card component with level h3" })
56
+
57
+ # Check progress
58
+ get_progress() # full overview
59
+ get_progress({ section: "Auth Module" }) # filtered to section
60
+ ```
61
+
62
+ ### Cross-Session Continuity
63
+
64
+ When you start a new session:
65
+ 1. `start_phase(N)` automatically includes implementation progress
66
+ 2. The agent sees what's done and picks up where it left off
67
+ 3. No repeated work, no drift
68
+
69
+ ---
70
+
71
+ ## Captain's Log (Project History)
72
+
73
+ Every `approve_phase()` auto-records a session entry to `.dndev/captain-log.json`. No manual action needed.
74
+
75
+ ### What's Recorded Automatically
76
+
77
+ - Date + timestamps (started/completed)
78
+ - Phase number and name
79
+ - Module (if scoped)
80
+ - Files touched + symbols used
81
+ - Outcome summary (from `complete_phase({ summary: "..." })`)
82
+
83
+ ### Viewing History
84
+
85
+ ```
86
+ get_project_history()
87
+ ```
88
+
89
+ Returns computed metrics + timeline:
90
+ - Total sessions, phases completed
91
+ - Files and symbols totals
92
+ - Per-session timeline with outcomes
93
+
94
+ ### Post-Mortem
95
+
96
+ The raw JSON at `.dndev/captain-log.json` enables:
97
+ - Phase velocity analysis (how many sessions per phase)
98
+ - Issue tracking across the project lifecycle
99
+ - Team-level comparison across projects
100
+
101
+ ---
102
+
18
103
  ## The Flow
19
104
 
20
105
  ```
21
- BRAINSTORM → SPEC → SCAFFOLD → ENTITIES → COMPOSE → CONFIGURE
106
+ BRAINSTORM (spec) → SCAFFOLD → ENTITIES → COMPOSE → CONFIGURE
22
107
  ```
23
108
 
24
- **Critical:** The spec is the OUTPUT of brainstorming, not the input. No code until spec is validated.
109
+ **Critical:** The spec is the OUTPUT of Phase 0 (BRAINSTORM), not a separate phase. No code until spec is validated.
25
110
 
26
111
  ---
27
112
 
@@ -267,94 +352,75 @@ Copy from `page_patterns.md`:
267
352
 
268
353
  ---
269
354
 
270
- ## Phase 4: CONFIGURE
355
+ ## Phase 4: CONFIGURE + TEST
271
356
 
272
- **Goal:** Finalize configuration and test.
357
+ **Goal:** Generate tests, firestore rules, CI/CD, and finalize config.
273
358
 
274
359
  **READ:**
360
+ - `guides/wai-way/spec_template.md` - The validated spec (your test plan)
361
+ - `entities/index.ts` - All entity definitions
275
362
  - `src/config/app.ts` - App configuration
276
- - `src/config/legal.ts` - Legal info
277
- - `.env` - Environment variables
363
+ - `guides/dndev/SETUP_TESTING.md` - Testing patterns
278
364
 
279
- ### Step 4.1: Update Configuration
365
+ ### Step 4.1: Generate Tests
280
366
 
281
- **app.ts:**
282
- - [ ] `APP_NAME` and `APP_SHORT_NAME`
283
- - [ ] Correct `preset`
284
- - [ ] Footer legal links
367
+ Call `get_guide("TESTING")` for patterns.
285
368
 
286
- **legal.ts:**
287
- - [ ] Company name and registration
288
- - [ ] Contact emails
289
- - [ ] Hosting provider
290
- - [ ] Jurisdiction
369
+ **Entity tests** — one per entity in `tests/entities/[Entity].test.ts`:
370
+ - [ ] Required fields defined
371
+ - [ ] Field types match spec
372
+ - [ ] Access rules match spec (create/read/update/delete per role)
291
373
 
292
- **.env:**
293
- - [ ] `VITE_FIREBASE_*` values
294
- - [ ] `VITE_DONOTDEV_LICENSE_KEY`
295
- - [ ] Optional: `VITE_STRIPE_*`, `VITE_SENTRY_DSN`
374
+ **Page tests** — one per page in `tests/pages/[Page].test.tsx`:
375
+ - [ ] Renders without error
376
+ - [ ] PageMeta defined (title, auth, admin)
377
+ - [ ] Route protection matches spec
296
378
 
297
- ### Step 4.2: Firebase Setup
379
+ **Access control tests** in `tests/access/access-rules.test.ts`:
380
+ - [ ] Admin entities require admin access
381
+ - [ ] User-owned entities have owner access
382
+ - [ ] No unauthenticated writes
298
383
 
299
- 1. Enable auth providers in Firebase Console
300
- 2. Create Firestore database
301
- 3. Deploy rules: `firebase deploy --only firestore:rules`
384
+ ### Step 4.2: Generate Firestore Rules
302
385
 
303
- ### Step 4.3: Test
386
+ Create `firestore.rules` from entity access definitions:
387
+ - `owner` → `resource.data.userId == request.auth.uid`
388
+ - `admin` → `request.auth.token.admin == true`
389
+ - `authenticated` → `request.auth != null`
304
390
 
305
- ```bash
306
- dndev emu start
307
- bun dev
308
- ```
391
+ ### Step 4.3: Generate CI/CD
309
392
 
310
- **Test checklist:**
311
- - [ ] Can create/login user
312
- - [ ] Public pages work without auth
313
- - [ ] Protected pages redirect to login
314
- - [ ] Admin pages require admin role
315
- - [ ] CRUD operations work
316
- - [ ] Data persists
393
+ Create `.github/workflows/ci.yml`:
394
+ - Quality job: `bun install` → `bun run type-check` → `bun test`
395
+ - Deploy job: `bun run build` Firebase deploy (on main push)
317
396
 
318
- ### Step 4.4: Mobile Check
397
+ ### Step 4.4: Update Configuration
319
398
 
320
- 1. Open DevTools (F12)
321
- 2. Toggle device toolbar (Ctrl+Shift+M)
322
- 3. Test at 375px width
399
+ **app.ts:** APP_NAME, APP_SHORT_NAME, preset, footer links
400
+ **legal.ts:** Company, contacts, hosting, jurisdiction
401
+ **.env:** VITE_FIREBASE_*, VITE_DONOTDEV_LICENSE_KEY, optional Stripe/Sentry
323
402
 
324
- **Output:** Working app with auth, CRUD, config complete.
403
+ ### Step 4.5: Run Tests
325
404
 
326
- ---
327
-
328
- ## Phase 5: i18n (Optional, After Validation)
405
+ ```bash
406
+ bun test
407
+ ```
329
408
 
330
- **Only after Phase 4 is validated.**
409
+ All tests must pass before completing.
331
410
 
332
- ### Step 5.1: Extract Strings
411
+ ### Step 4.6: Mobile Check
333
412
 
334
- Create `src/locales/[namespace]_en.json`:
335
- ```json
336
- {
337
- "hero": {
338
- "title": "Welcome to My App",
339
- "subtitle": "The best app ever built"
340
- }
341
- }
342
- ```
413
+ DevTools → 375px width → navigation, forms, text, buttons (44px), no horizontal scroll.
343
414
 
344
- ### Step 5.2: Replace Hardcoded Strings
415
+ **Output:** Test files, firestore.rules, CI/CD pipeline, configured app.
345
416
 
346
- ```tsx
347
- const { t } = useTranslation('home');
417
+ ---
348
418
 
349
- <HeroSection
350
- title={t('hero.title')}
351
- subtitle={t('hero.subtitle')}
352
- />
353
- ```
419
+ ### Step 4.7: i18n (Optional)
354
420
 
355
- ### Step 5.3: Add Translations
421
+ **Only after Steps 4.1-4.6 pass.**
356
422
 
357
- Copy `home_en.json` `home_fr.json`, translate values.
423
+ Extract hardcoded strings to `src/locales/[namespace]_en.json`, replace with `useTranslation()`.
358
424
 
359
425
  ---
360
426
 
@@ -381,10 +447,10 @@ Activate agent personas from `guides/wai-way/agents/`:
381
447
 
382
448
  | Agent | Phase | Focus |
383
449
  |-------|-------|-------|
384
- | **Extractor** | 1 | Routes, sitemap, PageMeta |
450
+ | **Extractor** | 0-1 | Requirements gathering, routes, sitemap, PageMeta |
385
451
  | **Architect** | 2 | Entities, data models |
386
452
  | **Builder** | 3 | Page composition, components |
387
- | **Polisher** | 4 | Config, testing, polish |
453
+ | **Polisher** | 4 | Config, testing, polish, i18n |
388
454
 
389
455
  See individual agent files for activation prompts.
390
456
 
@@ -397,8 +463,7 @@ Phase 0: BRAINSTORM → User idea → Agent questions → Agent fills spec → U
397
463
  Phase 1: SCAFFOLD → Create all *Page.tsx with PageMeta (from spec)
398
464
  Phase 2: ENTITIES → Define all entities with fields/access (from spec)
399
465
  Phase 3: COMPOSE → Build pages with components (HARDCODE strings)
400
- Phase 4: CONFIGURE → Config, Firebase, test, mobile
401
- Phase 5: i18n → (Optional) Extract strings, translate
466
+ Phase 4: CONFIGURE → Config, Firebase, test, mobile, optional i18n
402
467
  ```
403
468
 
404
469
  **Remember:** Spec is the OUTPUT of brainstorming. Validated spec = mechanical build.
@@ -10,27 +10,58 @@ agent:
10
10
  id: polisher
11
11
  title: QA & Config Specialist
12
12
  icon: 🧪
13
- phase: "4_configure_polish"
14
- done_when: "Config complete, tests pass, mobile responsive"
13
+ phase: "4_configure_test"
14
+ done_when: "Tests pass, config complete, firestore rules generated"
15
15
 
16
16
  persona:
17
- role: Quality Gatekeeper & Configuration Expert
18
- style: Detail-oriented, systematic, thorough
19
- identity: You ensure the app is configured correctly and production-ready.
20
- focus: Configuration, testing, mobile check, optional i18n.
17
+ role: Quality Gatekeeper & Test Generator
18
+ style: Systematic, thorough, test-driven
19
+ identity: You generate tests from the spec, configure the app, and verify everything works.
20
+ focus: Test generation, configuration, firestore rules, mobile check.
21
21
 
22
22
  golden_rule: |
23
- THE SCAFFOLDED FILES ARE YOUR DOCUMENTATION.
24
- READ src/config/app.ts for config options.
25
- READ src/config/legal.ts for legal checklist.
26
- READ src/themes.css for theme variables.
23
+ THE SPEC IS YOUR TEST PLAN.
24
+ READ the spec (Phase 0 output) for entities, permissions, journeys.
25
+ READ each entity file for access rules and fields.
26
+ GENERATE tests that verify the spec is implemented correctly.
27
27
 
28
28
  core_principles:
29
- - Configuration first: app.ts, legal.ts, .env
30
- - Test with emulators: dndev emu start
29
+ - Tests first: generate entity tests, page tests, access tests
30
+ - Firestore rules from entities: access definitions → security rules
31
+ - Configuration: app.ts, legal.ts, .env
31
32
  - Mobile check: 375px width
32
33
  - i18n is OPTIONAL and comes LAST
33
34
 
35
+ test_generation:
36
+ entity_tests:
37
+ per_entity:
38
+ - Required fields are defined
39
+ - Field types match spec
40
+ - Access rules match spec (create/read/update/delete per role)
41
+ - State transitions valid (if applicable)
42
+ output: "tests/entities/[EntityName].test.ts"
43
+ page_tests:
44
+ per_page:
45
+ - Renders without error
46
+ - PageMeta defined (title, auth, admin)
47
+ - Route protection matches spec
48
+ output: "tests/pages/[PageName].test.tsx"
49
+ access_tests:
50
+ - Admin entities require admin access
51
+ - User-owned entities have owner access
52
+ - Public entities allow guest read
53
+ - No unauthenticated writes
54
+ output: "tests/access/access-rules.test.ts"
55
+
56
+ firestore_rules:
57
+ source: "Entity access definitions"
58
+ mapping:
59
+ owner: "resource.data.userId == request.auth.uid"
60
+ admin: "request.auth.token.admin == true"
61
+ authenticated: "request.auth != null"
62
+ guest: "true"
63
+ output: "firestore.rules"
64
+
34
65
  config_checklist:
35
66
  app_ts:
36
67
  - APP_NAME and APP_SHORT_NAME set
@@ -45,32 +76,19 @@ config_checklist:
45
76
  - VITE_FIREBASE_* values set
46
77
  - VITE_DONOTDEV_LICENSE_KEY set
47
78
 
48
- test_checklist:
49
- - Can create/login user
50
- - Public pages work without auth
51
- - Protected pages redirect to login
52
- - Admin pages require admin role
53
- - CRUD operations work
54
- - Data persists
55
-
56
- mobile_check:
57
- - Open DevTools (F12)
58
- - Toggle device toolbar (Ctrl+Shift+M)
59
- - Test at 375px width
60
- - Navigation works
61
- - Forms are usable
62
- - Text is readable
63
-
64
79
  commands:
65
80
  - help: Show available commands
81
+ - generate-tests: Generate all test files from spec + entities
82
+ - generate-rules: Generate firestore.rules from entities
66
83
  - audit-config: Check configuration files
67
84
  - audit-mobile: Check mobile responsiveness
68
85
  - add-i18n: Extract strings to locales (optional)
69
86
  - exit: Exit persona
70
87
 
71
88
  output:
89
+ - Test files generated and passing
90
+ - Firestore rules generated
72
91
  - Configuration complete
73
- - All tests pass
74
92
  - Mobile responsive
75
93
  - (Optional) i18n added
76
94
  ```
@@ -81,20 +99,24 @@ output:
81
99
  Activate AGENT Polisher.
82
100
 
83
101
  READ these files first:
102
+ - guides/wai-way/spec_template.md (the validated spec — your test plan)
103
+ - entities/index.ts (all entity definitions)
104
+ - src/pages/ (all page files)
84
105
  - src/config/app.ts (app configuration)
85
- - src/config/legal.ts (legal info checklist)
86
- - src/themes.css (theme customization)
87
- - .env (environment variables)
88
-
89
- Your goal: Finalize configuration and test the app.
90
-
91
- Checklist:
92
- 1. Update app.ts (name, preset, footer)
93
- 2. Update legal.ts (company, contacts)
94
- 3. Fill .env (Firebase config)
95
- 4. Test with emulators
96
- 5. Mobile check at 375px
97
- 6. (Optional) Add i18n
98
-
99
- Verify each item before marking complete.
106
+ - guides/dndev/SETUP_TESTING.md (testing patterns)
107
+
108
+ Your goal: Generate tests, firestore rules, and finalize config.
109
+
110
+ Steps:
111
+ 1. Create vitest.config.ts + tests/setup.ts
112
+ 2. Generate entity tests (one per entity from entities/)
113
+ 3. Generate page tests (one per page from src/pages/)
114
+ 4. Generate access control tests (from spec permissions)
115
+ 5. Generate firestore.rules (from entity access definitions)
116
+ 6. Update app.ts, legal.ts, .env
117
+ 7. Run bun test — all must pass
118
+ 8. Mobile check at 375px
119
+ 9. (Optional) Add i18n
120
+
121
+ Call get_guide("TESTING") for testing patterns.
100
122
  ```
@@ -2,7 +2,16 @@
2
2
 
3
3
  **Goal:** Deeply understand the app and document ALL requirements before any code.
4
4
 
5
- **Done when:** spec_template.md is COMPLETE with user flows, business rules, and entity relationships - AND user has validated it.
5
+ **MCP:** `start_phase(0)` to begin. `complete_phase()` when done.
6
+ **Done when:** `spec_template.md` is COMPLETE and user has validated it.
7
+
8
+ ---
9
+
10
+ ## First: Call list_features()
11
+
12
+ **Before probing the user or designing anything**, call `list_features()`.
13
+
14
+ It returns a one-line summary from each framework package README (core, ui, templates, auth, billing, etc.). Use it to avoid designing custom solutions when the framework already provides them (e.g. blog, CRUD, billing pages). If you skip this, you may propose work that already exists in `@donotdev/templates` or other packages.
6
15
 
7
16
  ---
8
17
 
@@ -26,6 +35,8 @@ Before moving to Phase 1, you MUST have:
26
35
  ```
27
36
  User provides idea
28
37
 
38
+ Agent calls list_features() → matches needs to existing framework capabilities
39
+
29
40
  Agent asks IDENTITY questions (who, what, why)
30
41
 
31
42
  Agent asks USER JOURNEY questions (what do users DO step by step?)
@@ -277,5 +288,11 @@ Completed spec_template.md with:
277
288
  - All permissions defined
278
289
  - User validation
279
290
 
291
+ **After spec validation, generate the implementation tracker:**
292
+ ```
293
+ init_implementation({ from_spec: true })
294
+ ```
295
+ This creates `.dndev/implementation.md` with checklist items for all phases (pages, entities, composition, config). Agents will read and update this file across sessions.
296
+
280
297
  **Spec validated AND complete? Move to Phase 1: SCAFFOLD.**
281
298
  **Anything unclear? Keep asking questions.**
@@ -2,6 +2,7 @@
2
2
 
3
3
  **Goal:** Running app with all routes defined.
4
4
 
5
+ **MCP:** `start_phase(1)` to begin. `complete_phase()` when done.
5
6
  **Done when:** All routes listed, all *Page.tsx files created with correct PageMeta.
6
7
 
7
8
  **Prerequisite:** Phase 0 (spec) must be complete.
@@ -1,7 +1,8 @@
1
1
  # BLUEPRINT: 2_ENTITIES
2
2
 
3
- **Goal:** Define all data models from spec.
3
+ **Goal:** Define all data models from spec (Single Source of Truth).
4
4
 
5
+ **MCP:** `start_phase(2)` to begin. Use `lookup_symbol('defineEntity')` for types. `complete_phase()` when done.
5
6
  **Done when:** All entities defined with fields, access rules, visibility. Exported from index.ts.
6
7
 
7
8
  **Prerequisite:** Phase 0 (spec) and Phase 1 (scaffold) complete.
@@ -2,6 +2,7 @@
2
2
 
3
3
  **Goal:** Build pages with components. HARDCODE ALL STRINGS.
4
4
 
5
+ **MCP:** `start_phase(3)` to begin. Use `lookup_symbol(component_name)` for types. `complete_phase()` when done.
5
6
  **Done when:** All pages functional with content. CRUD pages use EntityList/EntityFormRenderer. All strings hardcoded.
6
7
 
7
8
  **Prerequisite:** Phase 0-2 complete. Spec validated, entities defined.
@@ -111,7 +112,7 @@ Copy Landing pattern from `page_patterns.md`:
111
112
  />
112
113
  ```
113
114
 
114
- Validate UX in one language. Add i18n in Phase 5.
115
+ Validate UX in one language. Add i18n in Phase 4 (CONFIGURE) after validation.
115
116
 
116
117
  ---
117
118