@kidlat-dakila/flightplan 0.1.6 → 0.1.8

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 (178) hide show
  1. package/README.md +31 -16
  2. package/backend/configurations/default-configurations/minimal/context.md +9 -54
  3. package/backend/configurations/default-configurations/minimal/traceDiagram.nodes.blockLabels.label.md +19 -0
  4. package/backend/configurations/default-configurations/minimal/{journey.nodes.description.md → traceDiagram.nodes.description.md} +1 -1
  5. package/backend/configurations/default-configurations/minimal/walkthrough.files.waypoints.reading.md +1 -1
  6. package/backend/configurations/default-configurations/onboardee/context.md +16 -62
  7. package/backend/configurations/default-configurations/onboardee/traceDiagram.description.md +16 -0
  8. package/backend/configurations/default-configurations/onboardee/traceDiagram.nodes.blockLabels.label.md +11 -0
  9. package/backend/configurations/default-configurations/onboardee/{journey.nodes.description.md → traceDiagram.nodes.description.md} +1 -1
  10. package/backend/configurations/default-configurations/onboardee/walkthrough.files.waypoints.reading.md +1 -1
  11. package/backend/configurations/default-configurations/standard/context.md +16 -62
  12. package/backend/configurations/default-configurations/standard/traceDiagram.description.md +16 -0
  13. package/backend/configurations/default-configurations/standard/traceDiagram.nodes.blockLabels.label.md +11 -0
  14. package/backend/configurations/default-configurations/standard/{journey.nodes.description.md → traceDiagram.nodes.description.md} +1 -1
  15. package/backend/configurations/default-configurations/standard/walkthrough.files.waypoints.reading.md +1 -1
  16. package/backend/configurations/default-configurations/unfamiliar-territory/context.md +16 -62
  17. package/backend/configurations/default-configurations/unfamiliar-territory/traceDiagram.description.md +16 -0
  18. package/backend/configurations/default-configurations/unfamiliar-territory/traceDiagram.nodes.blockLabels.label.md +11 -0
  19. package/backend/configurations/default-configurations/unfamiliar-territory/{journey.nodes.description.md → traceDiagram.nodes.description.md} +1 -1
  20. package/backend/configurations/default-configurations/unfamiliar-territory/walkthrough.files.waypoints.reading.md +1 -1
  21. package/backend/configurations/system-instructions/artifactFormat.md +20 -16
  22. package/backend/configurations/system-instructions/{blast.md → blastDiagram.md} +5 -5
  23. package/backend/configurations/system-instructions/context.md +18 -9
  24. package/backend/configurations/system-instructions/title.md +36 -4
  25. package/backend/configurations/system-instructions/traceDiagram.description.md +14 -0
  26. package/backend/configurations/system-instructions/{journey.md → traceDiagram.md} +8 -8
  27. package/backend/configurations/system-instructions/traceDiagram.nodes.blockLabels.label.md +6 -0
  28. package/backend/configurations/system-instructions/walkthrough.files.md +5 -11
  29. package/backend/configurations/system-instructions/walkthrough.files.waypoints.coreChange.md +7 -0
  30. package/backend/configurations/system-instructions/walkthrough.files.waypoints.md +3 -3
  31. package/backend/configurations/system-instructions/walkthrough.md +6 -8
  32. package/backend/main.js +56748 -44939
  33. package/backend/plugin/skills/live/SKILL.md +79 -0
  34. package/backend/plugin/skills/review/SKILL.md +39 -52
  35. package/frontend/assets/_branchId-Caxyy__g.js +1 -0
  36. package/frontend/assets/_branchId-IJ4VEzEl.js +1 -0
  37. package/frontend/assets/_id-3L9ONe4W.js +1 -0
  38. package/frontend/assets/_id-CvORsoNj.js +1 -0
  39. package/frontend/assets/agents-DnjhKMUc.js +1 -0
  40. package/frontend/assets/agents-bla75JmI.js +1 -0
  41. package/frontend/assets/create-B82q7ZMu.js +1 -0
  42. package/frontend/assets/create-C9yw-thL.js +1 -0
  43. package/frontend/assets/{create-DBv4ZLt7.js → create-CEpA1s8S.js} +1 -1
  44. package/frontend/assets/create-D0h6PRxn.js +1 -0
  45. package/frontend/assets/download-CwWMZwNG.js +1 -0
  46. package/frontend/assets/forges-BH3uXIQL.js +1 -0
  47. package/frontend/assets/forges-uSh1-w20.js +1 -0
  48. package/frontend/assets/index--nj01XKS.js +1 -0
  49. package/frontend/assets/index-0VAWT0gs.js +1 -0
  50. package/frontend/assets/index-B0zuYONu.js +1 -0
  51. package/frontend/assets/{index-XcYy-NBi.js → index-BQaZ5gZR.js} +1 -1
  52. package/frontend/assets/{index-CZN7BV83.js → index-BZ6iL63Z.js} +1 -1
  53. package/frontend/assets/index-Bar8NyIm.js +1 -0
  54. package/frontend/assets/{index-efpZ6EEe.js → index-BlTfCkr5.js} +1 -1
  55. package/frontend/assets/{index-Dn9qaXzX.js → index-BvuPClj3.js} +1 -1
  56. package/frontend/assets/index-C9xsdcXo.js +1 -0
  57. package/frontend/assets/index-CJDNq1TA.js +1 -0
  58. package/frontend/assets/index-CJslcuJ0.js +1 -0
  59. package/frontend/assets/index-CTKqkqZN.css +1 -0
  60. package/frontend/assets/index-CXyB0ld0.js +1 -0
  61. package/frontend/assets/{index-DyfuBbIJ.js → index-CcORd1N6.js} +1 -1
  62. package/frontend/assets/index-CrAQ5_e4.js +1 -0
  63. package/frontend/assets/index-DG0FDX8u.js +1 -0
  64. package/frontend/assets/index-DKnoo-kT.js +455 -0
  65. package/frontend/assets/{index-s14Wy6CE.js → index-DKzDkR6v.js} +1 -1
  66. package/frontend/assets/{index-CR5UGYQN.js → index-DfKNJbUM.js} +75 -62
  67. package/frontend/assets/{index-BaflOxvR.js → index-DlUHisPA.js} +1 -1
  68. package/frontend/assets/index-Dv5cF6qF.js +1 -0
  69. package/frontend/assets/index-JPWJ3IiN.js +1 -0
  70. package/frontend/assets/index-V1avMli5.js +6 -0
  71. package/frontend/assets/index-iRAoFOv3.js +1 -0
  72. package/frontend/assets/repositories-DqGU7W63.js +1 -0
  73. package/frontend/assets/repositories-DuObN8PJ.js +1 -0
  74. package/frontend/assets/review-BbbMUFsk.js +1 -0
  75. package/frontend/assets/review-C3k0h5Vl.js +1 -0
  76. package/frontend/assets/route-D8s8AylJ.js +1 -0
  77. package/frontend/favicon.ico +0 -0
  78. package/frontend/favicon.svg +5 -0
  79. package/frontend/index.html +10 -3
  80. package/frontend/logo.svg +5 -0
  81. package/frontend/not-found.svg +25 -0
  82. package/frontend/server-error.svg +32 -0
  83. package/package.json +5 -2
  84. package/published-review/app.css +1 -1
  85. package/published-review/app.js +134 -99
  86. package/backend/configurations/default-configurations/minimal/journey.nodes.blockLabels.label.md +0 -13
  87. package/backend/configurations/default-configurations/minimal/walkthrough.files.title.md +0 -7
  88. package/backend/configurations/default-configurations/minimal/walkthrough.intro.md +0 -4
  89. package/backend/configurations/default-configurations/onboardee/journey.description.md +0 -10
  90. package/backend/configurations/default-configurations/onboardee/journey.nodes.blockLabels.label.md +0 -9
  91. package/backend/configurations/default-configurations/onboardee/walkthrough.files.title.md +0 -7
  92. package/backend/configurations/default-configurations/onboardee/walkthrough.intro.md +0 -5
  93. package/backend/configurations/default-configurations/standard/journey.description.md +0 -10
  94. package/backend/configurations/default-configurations/standard/journey.nodes.blockLabels.label.md +0 -9
  95. package/backend/configurations/default-configurations/standard/walkthrough.files.title.md +0 -7
  96. package/backend/configurations/default-configurations/standard/walkthrough.intro.md +0 -5
  97. package/backend/configurations/default-configurations/unfamiliar-territory/journey.description.md +0 -10
  98. package/backend/configurations/default-configurations/unfamiliar-territory/journey.nodes.blockLabels.label.md +0 -9
  99. package/backend/configurations/default-configurations/unfamiliar-territory/walkthrough.files.title.md +0 -7
  100. package/backend/configurations/default-configurations/unfamiliar-territory/walkthrough.intro.md +0 -5
  101. package/backend/configurations/system-instructions/journey.description.md +0 -14
  102. package/backend/configurations/system-instructions/journey.nodes.blockLabels.label.md +0 -6
  103. package/backend/configurations/system-instructions/walkthrough.files.summary.md +0 -4
  104. package/backend/configurations/system-instructions/walkthrough.files.title.md +0 -2
  105. package/backend/configurations/system-instructions/walkthrough.files.waypoints.needsAttention.md +0 -8
  106. package/backend/configurations/system-instructions/walkthrough.intro.md +0 -3
  107. package/frontend/assets/_branchId-CPb8-qBw.js +0 -1
  108. package/frontend/assets/_branchId-LiwHskkW.js +0 -1
  109. package/frontend/assets/_id-BDFgPH36.js +0 -1
  110. package/frontend/assets/_id-DlHylI1F.js +0 -1
  111. package/frontend/assets/agents-BGNiGYQQ.js +0 -1
  112. package/frontend/assets/agents-DBPulyWi.js +0 -1
  113. package/frontend/assets/configuration-C8ZTSPna.js +0 -1
  114. package/frontend/assets/configuration-DBU-Fvop.js +0 -1
  115. package/frontend/assets/create-BWsYjEs5.js +0 -1
  116. package/frontend/assets/create-DBNC2wSp.js +0 -1
  117. package/frontend/assets/create-DXgFUVIW.js +0 -1
  118. package/frontend/assets/download-BnmEn_Ca.js +0 -1
  119. package/frontend/assets/forges-BOWrvfZl.js +0 -1
  120. package/frontend/assets/forges-DwSiwqas.js +0 -1
  121. package/frontend/assets/index-B1Rm0SQ5.js +0 -1
  122. package/frontend/assets/index-BKKD-dvv.js +0 -1
  123. package/frontend/assets/index-CSoB1eP_.js +0 -1
  124. package/frontend/assets/index-CUqlioqL.js +0 -1
  125. package/frontend/assets/index-CeY9TXPf.js +0 -1
  126. package/frontend/assets/index-CydhSU9g.js +0 -1
  127. package/frontend/assets/index-D-k5POv5.js +0 -1
  128. package/frontend/assets/index-DCCyA67N.js +0 -1
  129. package/frontend/assets/index-DfRj4oZV.js +0 -441
  130. package/frontend/assets/index-Dw5NpM9d.js +0 -1
  131. package/frontend/assets/index-PzkXPYSX.js +0 -1
  132. package/frontend/assets/index-QabB0_Qw.js +0 -1
  133. package/frontend/assets/index-V8tnJR9v.js +0 -1
  134. package/frontend/assets/index-ec_xLUMF.css +0 -1
  135. package/frontend/assets/index-zxLaxo8R.js +0 -1
  136. package/frontend/assets/repositories-BLLfYDjf.js +0 -1
  137. package/frontend/assets/repositories-of9BXUjW.js +0 -1
  138. package/frontend/assets/route-X94hglR1.js +0 -1
  139. package/frontend/logo-small.png +0 -0
  140. package/frontend/logo.png +0 -0
  141. /package/backend/configurations/default-configurations/minimal/{blast.nodes.impactReason.md → blastDiagram.nodes.impactReason.md} +0 -0
  142. /package/backend/configurations/default-configurations/minimal/{blast.nodes.impactType.behaviour-changes.md → blastDiagram.nodes.impactType.behaviour-changes.md} +0 -0
  143. /package/backend/configurations/default-configurations/minimal/{blast.nodes.impactType.breaks.md → blastDiagram.nodes.impactType.breaks.md} +0 -0
  144. /package/backend/configurations/default-configurations/minimal/{blast.nodes.impactType.md → blastDiagram.nodes.impactType.md} +0 -0
  145. /package/backend/configurations/default-configurations/minimal/{blast.nodes.impactType.unaffected.md → blastDiagram.nodes.impactType.unaffected.md} +0 -0
  146. /package/backend/configurations/default-configurations/minimal/{journey.description.md → traceDiagram.description.md} +0 -0
  147. /package/backend/configurations/default-configurations/minimal/{journey.nodes.label.md → traceDiagram.nodes.label.md} +0 -0
  148. /package/backend/configurations/default-configurations/minimal/{journey.nodes.triggerLabels.label.md → traceDiagram.nodes.triggerLabels.label.md} +0 -0
  149. /package/backend/configurations/default-configurations/minimal/{walkthrough.files.waypoints.needsAttention.md → walkthrough.files.waypoints.coreChange.md} +0 -0
  150. /package/backend/configurations/default-configurations/onboardee/{blast.nodes.impactReason.md → blastDiagram.nodes.impactReason.md} +0 -0
  151. /package/backend/configurations/default-configurations/onboardee/{blast.nodes.impactType.behaviour-changes.md → blastDiagram.nodes.impactType.behaviour-changes.md} +0 -0
  152. /package/backend/configurations/default-configurations/onboardee/{blast.nodes.impactType.breaks.md → blastDiagram.nodes.impactType.breaks.md} +0 -0
  153. /package/backend/configurations/default-configurations/onboardee/{blast.nodes.impactType.md → blastDiagram.nodes.impactType.md} +0 -0
  154. /package/backend/configurations/default-configurations/onboardee/{blast.nodes.impactType.unaffected.md → blastDiagram.nodes.impactType.unaffected.md} +0 -0
  155. /package/backend/configurations/default-configurations/onboardee/{journey.nodes.label.md → traceDiagram.nodes.label.md} +0 -0
  156. /package/backend/configurations/default-configurations/onboardee/{journey.nodes.triggerLabels.label.md → traceDiagram.nodes.triggerLabels.label.md} +0 -0
  157. /package/backend/configurations/default-configurations/onboardee/{walkthrough.files.waypoints.needsAttention.md → walkthrough.files.waypoints.coreChange.md} +0 -0
  158. /package/backend/configurations/default-configurations/standard/{blast.nodes.impactReason.md → blastDiagram.nodes.impactReason.md} +0 -0
  159. /package/backend/configurations/default-configurations/standard/{blast.nodes.impactType.behaviour-changes.md → blastDiagram.nodes.impactType.behaviour-changes.md} +0 -0
  160. /package/backend/configurations/default-configurations/standard/{blast.nodes.impactType.breaks.md → blastDiagram.nodes.impactType.breaks.md} +0 -0
  161. /package/backend/configurations/default-configurations/standard/{blast.nodes.impactType.md → blastDiagram.nodes.impactType.md} +0 -0
  162. /package/backend/configurations/default-configurations/standard/{blast.nodes.impactType.unaffected.md → blastDiagram.nodes.impactType.unaffected.md} +0 -0
  163. /package/backend/configurations/default-configurations/standard/{journey.nodes.label.md → traceDiagram.nodes.label.md} +0 -0
  164. /package/backend/configurations/default-configurations/standard/{journey.nodes.triggerLabels.label.md → traceDiagram.nodes.triggerLabels.label.md} +0 -0
  165. /package/backend/configurations/default-configurations/standard/{walkthrough.files.waypoints.needsAttention.md → walkthrough.files.waypoints.coreChange.md} +0 -0
  166. /package/backend/configurations/default-configurations/unfamiliar-territory/{blast.nodes.impactReason.md → blastDiagram.nodes.impactReason.md} +0 -0
  167. /package/backend/configurations/default-configurations/unfamiliar-territory/{blast.nodes.impactType.behaviour-changes.md → blastDiagram.nodes.impactType.behaviour-changes.md} +0 -0
  168. /package/backend/configurations/default-configurations/unfamiliar-territory/{blast.nodes.impactType.breaks.md → blastDiagram.nodes.impactType.breaks.md} +0 -0
  169. /package/backend/configurations/default-configurations/unfamiliar-territory/{blast.nodes.impactType.md → blastDiagram.nodes.impactType.md} +0 -0
  170. /package/backend/configurations/default-configurations/unfamiliar-territory/{blast.nodes.impactType.unaffected.md → blastDiagram.nodes.impactType.unaffected.md} +0 -0
  171. /package/backend/configurations/default-configurations/unfamiliar-territory/{journey.nodes.label.md → traceDiagram.nodes.label.md} +0 -0
  172. /package/backend/configurations/default-configurations/unfamiliar-territory/{journey.nodes.triggerLabels.label.md → traceDiagram.nodes.triggerLabels.label.md} +0 -0
  173. /package/backend/configurations/default-configurations/unfamiliar-territory/{walkthrough.files.waypoints.needsAttention.md → walkthrough.files.waypoints.coreChange.md} +0 -0
  174. /package/backend/configurations/system-instructions/{blast.nodes.impactReason.md → blastDiagram.nodes.impactReason.md} +0 -0
  175. /package/backend/configurations/system-instructions/{blast.nodes.impactType.md → blastDiagram.nodes.impactType.md} +0 -0
  176. /package/backend/configurations/system-instructions/{journey.nodes.description.md → traceDiagram.nodes.description.md} +0 -0
  177. /package/backend/configurations/system-instructions/{journey.nodes.label.md → traceDiagram.nodes.label.md} +0 -0
  178. /package/backend/configurations/system-instructions/{journey.nodes.triggerLabels.label.md → traceDiagram.nodes.triggerLabels.label.md} +0 -0
package/README.md CHANGED
@@ -1,21 +1,29 @@
1
1
  # Flight Plan
2
2
 
3
- Read a pull request the way its author would explain it, instead of as a list of files.
3
+ [![CI](https://github.com/kidlat-dakila/flight-plan/actions/workflows/ci.yml/badge.svg)](https://github.com/kidlat-dakila/flight-plan/actions/workflows/ci.yml)
4
+ [![CodeQL](https://github.com/kidlat-dakila/flight-plan/actions/workflows/codeql.yml/badge.svg)](https://github.com/kidlat-dakila/flight-plan/actions/workflows/codeql.yml)
5
+ [![OpenSSF Scorecard](https://api.scorecard.dev/projects/github.com/kidlat-dakila/flight-plan/badge)](https://scorecard.dev/viewer/?uri=github.com/kidlat-dakila/flight-plan)
6
+ [![Socket](https://socket.dev/api/badge/npm/package/@kidlat-dakila/flightplan)](https://socket.dev/npm/package/@kidlat-dakila/flightplan)
4
7
 
5
- Flight Plan turns a pull request, or a branch with no pull request, into a guided review. Your coding agent writes a
6
- review artifact through Flight Plan's MCP tools, and a local web app shows it next to the code it describes. A review
7
- answers four questions a diff does not: why the change exists, how it runs, what it can affect, and where to look.
8
+ An offline-first code review tool that helps you understand and navigate the changes in a pull request.
8
9
 
9
- The structure of a review comes from the code, not from the agent. Flight Plan reads the syntax trees to work out who
10
- calls what, so the agent cannot leave a caller out or invent one. The agent writes only the prose.
10
+ Flight Plan reads the code of a pull request, or of a branch with no pull request, and lays the change out as a guided
11
+ review in a local web app, next to the code it describes. It shows how the change runs, what it can affect, and where to
12
+ look. It works from your local git checkout, and connects to GitHub, GitLab or Bitbucket for their pull requests,
13
+ comments and reviews.
14
+
15
+ Flight Plan builds the review from the code itself, with no model involved. It reads the syntax trees to work out who
16
+ calls what, then draws the diagrams and lays out the walkthrough from them. A coding agent can fill in the prose through
17
+ Flight Plan's MCP tools: why the change exists, the labels, the explanations and the findings. It writes only that
18
+ prose, so it cannot leave a caller out or invent one.
11
19
 
12
20
  ## Running it
13
21
 
14
22
  ```bash
15
- npx @kidlat-dakila/flightplan
23
+ npx @kidlat-dakila/flightplan@latest
16
24
  ```
17
25
 
18
- You can also install it once with `npm install -g @kidlat-dakila/flightplan` and then run `flightplan`. The command
26
+ You can also install it once with `npm install -g @kidlat-dakila/flightplan@latest` and then run `flightplan`. The command
19
27
  starts one local server for the web app, the API and the MCP endpoint, and opens it in the browser at
20
28
  `http://localhost:24747`.
21
29
 
@@ -49,14 +57,14 @@ You can change all of these later in **Settings**. Flight Plan acts on your forg
49
57
  1. Open a repository on the homepage, then pick a pull request or a branch.
50
58
  2. Make a review request: choose the configuration, the order of the Code Walkthrough and the agent. Flight Plan can
51
59
  start Claude Code for you. With any other agent, copy the prompt it gives you into your own agent session.
52
- 3. Flight Plan builds the structure of the review from the change, and the page opens it at once. Each part fills in as
53
- the agent writes it, and the page shows how much is written.
60
+ 3. Flight Plan builds the review from the change, and the page opens it at once, ready to read. The prose of each part
61
+ fills in as the agent writes it, and the page shows how much is written.
54
62
  4. When the agent finishes, the browser notifies you.
55
63
 
56
64
  A review artifact has these parts:
57
65
 
58
66
  - **Context**: why the change exists, in a few sentences to read before any code.
59
- - **Journey Flow Diagram**: how execution reaches the changed code, from whatever starts it.
67
+ - **Trace Diagram**: how execution reaches the changed code, from whatever starts it.
60
68
  - **Blast Diagram**: the files connected to the change through imports, and what the change does to the ones it did
61
69
  not touch.
62
70
  - **Code Walkthrough**: the changed code, one file at a time, with each explanation on the lines it is about and
@@ -134,15 +142,22 @@ pnpm install
134
142
  pnpm dev
135
143
  ```
136
144
 
137
- `pnpm dev` runs the backend on `http://localhost:3000` (tRPC at `/api/trpc`, MCP at `POST /mcp`) and the frontend on
138
- `http://localhost:4200`, which proxies `/api` to the backend.
145
+ `pnpm dev` runs the backend on `http://localhost:3000` (tRPC at `/api/trpc`, MCP at `POST /mcp`), the frontend on
146
+ `http://localhost:4200`, which proxies `/api` to the backend, and the site on `http://localhost:4400`.
139
147
 
140
148
  `pnpm install` also installs a pre-commit hook (husky) that runs ESLint and type-checking for the projects a commit
141
149
  touches.
142
150
 
143
- `pnpm build:prod` builds the production bundle and puts together the npm package in `dist/package`. Publish it from
144
- there with `npm publish`. `pnpm start` runs that build the way the `flightplan` command does, without building it
145
- first.
151
+ `pnpm build:prod` builds the production bundle and puts together the npm package in `dist/package`. `pnpm start` runs
152
+ that build the way the `flightplan` command does, without building it first.
153
+
154
+ To release, bump `version` in `package.json`, then build the package and publish it to npm from your machine:
155
+
156
+ ```bash
157
+ pnpm prod:release
158
+ ```
159
+
160
+ It publishes the version that `package.json` holds, so log in with `npm login` first.
146
161
 
147
162
  Run checks through Nx:
148
163
 
@@ -1,58 +1,13 @@
1
- Three parts, this order: opening paragraph, `## Overview`, `## Implementation`.
1
+ One or two sentences starting "This segment": what the segment's change does.
2
+ Nothing else. Flight Plan lists what the segment adds, modifies and removes in
3
+ the Change Overview under it: no list, no accordion, no code links.
2
4
 
3
5
  ```markdown
4
- Basket with item sold out a minute ago still reached payment. Shopper now told
5
- of every such item before paying.
6
-
7
- ## Overview
8
-
9
- - **When** customer submits basket with two lines out of stock, **then**
10
- [error names both lines](code:src/stock/check.ts#hasStock).
11
- - **When** every line in stock, **then** nothing changes.
12
-
13
- ## Implementation
14
-
15
- **`src/stock/`**
16
-
17
- - Modified [`hasStock()`](code:src/stock/check.ts#hasStock): reads every level
18
- once, collects every short line.
6
+ This segment checks stock of every basket line before payment. A basket with an
7
+ item sold out a minute ago gets an error naming each one.
19
8
  ```
20
9
 
21
- **Verify every claim against the diff.** Never against the pull request's own
22
- description.
23
-
24
- ### Opening paragraph
25
-
26
- Why anyone should care. Reader has not seen the code.
27
-
28
- **No identifiers, no paths, no links here.** Cannot write it without a symbol:
29
- you describe implementation, not the change. Say what the reader would see: not
30
- "size check handles oversized query" but "query over 1 MB now gets error naming
31
- 1 MB limit".
32
-
33
- Three fragments at most, even for a large change.
34
-
35
- ### Overview
36
-
37
- What changes from outside the code. List of scenarios. One line each: bold
38
- **When**, situation, bold **then**, what can be observed.
39
-
40
- - **Situation**: reader's terms, one clause. What a person outside the code
41
- does, or the state that holds. Not the code path.
42
- - **Observed**: result a person or another system sees. Not mechanism. Link the
43
- code the result comes from.
44
- - **"nothing changes"**: where a reader would expect a change and there is
45
- none. No link.
46
-
47
- ### Implementation
48
-
49
- What changed inside the code, grouped by where it lives. Each group: bold label
50
- on its own line, then list.
51
-
52
- - **Label**: file, or directory when several files inside change. No verb. Group
53
- by place, not theme. Groups in the order the tour walks them.
54
- - **Item**: one change a reader would notice. Verb first, then the code:
55
- "Modified `hasStock()`: reads every level once, collects every short line."
56
- Link the code.
57
- - Item naming no code: only for a configuration value, a deleted file, the
58
- tests. No link.
10
+ - Check every claim against the diff, never the pull request's description.
11
+ - Say what someone would see. No identifiers, paths or links.
12
+ - This segment's files only. With segments off, the first segment's context is
13
+ the whole change's: start "This change".
@@ -0,0 +1,19 @@
1
+ What this row of the node does, as a reader of the product: a verb first,
2
+ present tense: "Queries every Pokemon ordered by name", "Sends order to API".
3
+ Read the node's code first: label says what the block does, not what it is or
4
+ what it is called. "Queries every Pokemon ordered by name", not "Query of every
5
+ Pokemon".
6
+
7
+ - **Argument**: what the node does with it: `Filters Pokemon by this trainer`,
8
+ not `Trainer to filter by`.
9
+ - **State**: what the node keeps in it: `Keeps cart lines`, not `Cart lines`.
10
+ - **Hook**: what the node gets from it: `Gets mutation that applies promo code`.
11
+ - **Effect**: what it does, when: `Clears form after save`.
12
+ - **Call**: what is asked of the code it calls: `Saves renamed user`.
13
+ - **Value**: what the code that makes it does: `Queries every Pokemon ordered by
14
+ name`.
15
+ - **Step**: what the step does: `Returns error for empty title`. Condition: what
16
+ is checked. Step standing for several statements: what they do together.
17
+
18
+ No name of the code: row shows it under your label. Same shape and tense on
19
+ every block label of one node: each starts with a verb.
@@ -1,4 +1,4 @@
1
- The journey that reaches this node, in drawn order: "{who} {action}: {caller}
1
+ The trace that reaches this node, in drawn order: "{who} {action}: {caller}
2
2
  {calls, renders or reads} this {what}." Start with what starts the path, name
3
3
  each step between, end on what hands over to it.
4
4
 
@@ -40,7 +40,7 @@ this card must know why it is in the pull request. Cause not clear from order of
40
40
  fragments: write _so_ or _because_.
41
41
 
42
42
  **Consumer from the Blast Diagram, not a guess.** Where the artifact has one,
43
- `blast` lists files importing this card's file, with `impactType` and
43
+ `blastDiagram` lists files importing this card's file, with `impactType` and
44
44
  `impactReason`. Name the one this card exists for. Link it. Nothing outside the
45
45
  change reaches this code: name what inside the pull request uses it. Neither
46
46
  shows a reason: say what the change does to its consumer, stop. Never invent the
@@ -1,70 +1,24 @@
1
- Write three parts, in this order: an opening paragraph, then `## Overview`, then
2
- `## Implementation`.
1
+ Write one or two sentences that start with "This segment" and say what the
2
+ segment's change does. That is the whole context. Flight Plan lists every piece
3
+ of code the segment adds, modifies and removes under it, in the Change Overview,
4
+ so the context holds no list of changes, no accordion and no code links.
3
5
 
4
6
  ```markdown
5
- A basket with an item that sold out a minute ago could still reach payment. The
6
- shopper now hears about every such item before paying.
7
-
8
- ## Overview
9
-
10
- - **When** a customer submits a basket with two lines out of stock, **then**
11
- [the error names both lines](code:src/stock/check.ts#hasStock).
12
- - **When** every line is in stock, **then** nothing changes.
13
-
14
- ## Implementation
15
-
16
- **`src/stock/`**
17
-
18
- - Modified [`hasStock()`](code:src/stock/check.ts#hasStock) to read every level
19
- once and collect every short line.
7
+ This segment checks the stock of every basket line before payment, so a basket
8
+ with an item that sold out a minute ago gets an error naming each sold-out item
9
+ and never reaches payment.
20
10
  ```
21
11
 
22
- **Verify every claim against the diff**, never against a pull request's own
12
+ Check every claim against the diff, never against the pull request's own
23
13
  description.
24
14
 
25
- ### The opening paragraph
26
-
27
- Say why anyone should care, to a reader who has not seen the code.
28
-
29
- **This paragraph bans identifiers, paths and links.** If you cannot write it
30
- without naming a symbol, you are describing the implementation rather than the
31
- change. That ban is what makes it the easiest place to hide a vague verb, so say
32
- what the reader would see: not "the size check handles an oversized query" but
33
- "a query over 1 MB now gets an error that names the 1 MB limit".
34
-
35
- Five sentences, and no more even when the change is large.
36
-
37
- ### Overview
38
-
39
- What changes from outside the code, as a list of scenarios. Each item is one
40
- sentence: a bold **When**, the situation, a bold **then**, what can be observed.
41
-
42
- The situation is in the reader's terms — one clause. Name what a person outside
43
- the code does, or the state that holds: "a customer submits a basket with two
44
- lines out of stock", "every line is in stock". Write the situation, not the code
45
- path that answers it.
46
-
47
- What can be observed is the result a person or another system sees, not the
48
- mechanism: "the error message names both out-of-stock lines". Link the code the
49
- result comes from where there is code to name.
50
-
51
- Say "nothing changes" when a reader would reasonably expect a change and there
52
- is none; that line stops a reviewer hunting for a regression that is not there.
53
- A "nothing changes" scenario carries no link.
54
-
55
- ### Implementation
56
-
57
- What changed inside the code, grouped by where it lives. Each group is a bold
58
- label on its own line, then a list of the changes there.
59
-
60
- The label is the place the changes live — a file, or a directory when several
61
- inside it are touched. It takes no verb. Group by where the code lives, not by
62
- theme, and put the groups in the order the tour walks them.
15
+ ### What the sentences say
63
16
 
64
- Each item is one change a reader would notice, as one sentence: the verb first,
65
- then the code it names. "Modified `hasStock()` to read every level once and
66
- collect every short line." Link the code the claim is about.
17
+ Say what the segment's change does for a reader who has not seen the code. Name
18
+ no identifiers, paths or links. Say what someone would see: "a query over 1 MB
19
+ now gets an error that names the limit" tells the reader more than "the size
20
+ check handles large queries".
67
21
 
68
- An item that names no code is usually one that has not been thought through. The
69
- exceptions are rare — a configuration value, a deleted file, the tests — and
70
- they carry no link.
22
+ Write about the files of this segment only. When the reviewer turned segments
23
+ off, the first segment's context is the one Context of the whole change: start
24
+ it with "This change" and say what the whole change does.
@@ -0,0 +1,16 @@
1
+ Write a caption for the diagram: what the reader is looking at, before they follow its lines. Two sentences at most.
2
+
3
+ - **The first sentence says what the diagram starts from.** Open with "This diagram shows how", name the page, the component, the job or the route the paths start at, and say what it does when it opens, loads or runs: `This diagram shows how the edit page loads an order and renders it in the form.` Use the verb of the code for what it does, such as renders, loads or requests, so that "shows" is not written twice.
4
+ - **The second sentence follows the user's actions.** The actions are the events on the diagram: a submit, a click, a pick, a typed value. Open with "It also shows what happens when the user", name the action as the user would, then say where its data ends up: the request it sends, the store it writes, the page it opens. `It also shows what happens when the user saves the order, and how the changed order reaches the API through updateOrder().`
5
+ - **Several actions.** Name them together, in the order the diagram draws them: `It also shows what happens when the user picks a customer, picks a product, types a quantity or submits the form.`
6
+ - **A path nobody clicks.** A request, a schedule or another system starts it: name that in place of the user. `It also shows what happens when a request reaches POST /orders, and how the order reaches the database.`
7
+ - **No action on the diagram.** Leave the second sentence out, and never write "It also shows" with nothing after it.
8
+ - **Shared code that other segments call.** Say what the diagram holds and what reaches it: `This diagram shows how the route table opens the order pages, and how each hook loads or sends orders through its request.`
9
+
10
+ Name where the data ends up, not the steps on the way: the labels and the descriptions of the nodes carry the steps, and the reader follows them on the board. Do not explain the change: the Context Section and the waypoints do.
11
+
12
+ | The diagram | Its caption |
13
+ |---|---|
14
+ | A page that loads a record and saves it | This diagram shows how the edit page loads an order and renders it in the form. It also shows what happens when the user saves the order, and how the changed order reaches the API through `updateOrder()`. |
15
+ | A page that creates a record | This diagram shows how the create page opens with an empty draft in the form. It also shows what happens when the user submits the form, and how the new order reaches the API through `createOrder()`. |
16
+ | A page with no action on its paths | This diagram shows how the orders list loads the orders and renders them in a table. |
@@ -0,0 +1,11 @@
1
+ Say what this row of the node does, as a reader of the product would. Start with a verb in the present tense: "Queries every Pokemon ordered by name", "Sends the order to the API". Read the code of the node first, so the label says what the block does, not what it is or what it is called: "Queries every Pokemon ordered by name", not "The query of every Pokemon".
2
+
3
+ - **An argument.** Say what the node does with the value it is given: `Filters the Pokemon by this trainer`, not `The trainer to filter by`.
4
+ - **A state.** Say what the node keeps in it: `Keeps the lines of the cart`, not `The lines of the cart`.
5
+ - **A hook.** Say what the node gets from it: `Gets the mutation that applies a promo code`.
6
+ - **An effect.** Say what it does and when: `Clears the form after a save`.
7
+ - **A call.** Say what is asked of the code it calls: `Saves the renamed user`.
8
+ - **A value.** Say what the code that makes it does: `Queries every Pokemon ordered by name`, not `The query of every Pokemon`.
9
+ - **A step.** Say what the step does: `Returns an error for an empty title`. For a condition, say what is checked: `Checks whether a trainer is given`. A step can stand for several statements that follow each other, listed by the first: say what they do together, `Renames the chosen user`.
10
+
11
+ Leave the name of the code out: the row shows it under your label. Keep the same shape and tense on every block label of one node: each one starts with a verb.
@@ -1,4 +1,4 @@
1
- Tell the journey that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
1
+ Tell the trace that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
2
2
 
3
3
  - **Several paths.** A node that more than one path reaches opens with one line that says so, then a list with one such sentence per path.
4
4
  - **A node with trigger labels.** Say what each event runs and what each fetch feeds, in the words of its trigger label: `When a shopper clicks "All", the handler calls setStatus(null) on the filter store.`
@@ -43,7 +43,7 @@ sort order, the option merge, the loop — unless that detail is the change itse
43
43
  change to the purpose `context` states, usually with _so that_ or _because_. A reviewer who reads
44
44
  only this card should know why it is in the pull request.
45
45
 
46
- **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blast` lists the files
46
+ **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blastDiagram` lists the files
47
47
  that import the file this card is in, and what the change does to each: its `impactType` and its `impactReason`. Name the one this card exists
48
48
  for — the form that no longer submits, the route that now returns something else, the caller that now
49
49
  depends on the new value — and link it. Where nothing outside the change reaches this code, name
@@ -1,70 +1,24 @@
1
- Write three parts, in this order: an opening paragraph, then `## Overview`, then
2
- `## Implementation`.
1
+ Write one or two sentences that start with "This segment" and say what the
2
+ segment's change does. That is the whole context. Flight Plan lists every piece
3
+ of code the segment adds, modifies and removes under it, in the Change Overview,
4
+ so the context holds no list of changes, no accordion and no code links.
3
5
 
4
6
  ```markdown
5
- A basket with an item that sold out a minute ago could still reach payment. The
6
- shopper now hears about every such item before paying.
7
-
8
- ## Overview
9
-
10
- - **When** a customer submits a basket with two lines out of stock, **then**
11
- [the error names both lines](code:src/stock/check.ts#hasStock).
12
- - **When** every line is in stock, **then** nothing changes.
13
-
14
- ## Implementation
15
-
16
- **`src/stock/`**
17
-
18
- - Modified [`hasStock()`](code:src/stock/check.ts#hasStock) to read every level
19
- once and collect every short line.
7
+ This segment checks the stock of every basket line before payment, so a basket
8
+ with an item that sold out a minute ago gets an error naming each sold-out item
9
+ and never reaches payment.
20
10
  ```
21
11
 
22
- **Verify every claim against the diff**, never against a pull request's own
12
+ Check every claim against the diff, never against the pull request's own
23
13
  description.
24
14
 
25
- ### The opening paragraph
26
-
27
- Say why anyone should care, to a reader who has not seen the code.
28
-
29
- **This paragraph bans identifiers, paths and links.** If you cannot write it
30
- without naming a symbol, you are describing the implementation rather than the
31
- change. That ban is what makes it the easiest place to hide a vague verb, so say
32
- what the reader would see: not "the size check handles an oversized query" but
33
- "a query over 1 MB now gets an error that names the 1 MB limit".
34
-
35
- Five sentences, and no more even when the change is large.
36
-
37
- ### Overview
38
-
39
- What changes from outside the code, as a list of scenarios. Each item is one
40
- sentence: a bold **When**, the situation, a bold **then**, what can be observed.
41
-
42
- The situation is in the reader's terms — one clause. Name what a person outside
43
- the code does, or the state that holds: "a customer submits a basket with two
44
- lines out of stock", "every line is in stock". Write the situation, not the code
45
- path that answers it.
46
-
47
- What can be observed is the result a person or another system sees, not the
48
- mechanism: "the error message names both out-of-stock lines". Link the code the
49
- result comes from where there is code to name.
50
-
51
- Say "nothing changes" when a reader would reasonably expect a change and there
52
- is none; that line stops a reviewer hunting for a regression that is not there.
53
- A "nothing changes" scenario carries no link.
54
-
55
- ### Implementation
56
-
57
- What changed inside the code, grouped by where it lives. Each group is a bold
58
- label on its own line, then a list of the changes there.
59
-
60
- The label is the place the changes live — a file, or a directory when several
61
- inside it are touched. It takes no verb. Group by where the code lives, not by
62
- theme, and put the groups in the order the tour walks them.
15
+ ### What the sentences say
63
16
 
64
- Each item is one change a reader would notice, as one sentence: the verb first,
65
- then the code it names. "Modified `hasStock()` to read every level once and
66
- collect every short line." Link the code the claim is about.
17
+ Say what the segment's change does for a reader who has not seen the code. Name
18
+ no identifiers, paths or links. Say what someone would see: "a query over 1 MB
19
+ now gets an error that names the limit" tells the reader more than "the size
20
+ check handles large queries".
67
21
 
68
- An item that names no code is usually one that has not been thought through. The
69
- exceptions are rare — a configuration value, a deleted file, the tests — and
70
- they carry no link.
22
+ Write about the files of this segment only. When the reviewer turned segments
23
+ off, the first segment's context is the one Context of the whole change: start
24
+ it with "This change" and say what the whole change does.
@@ -0,0 +1,16 @@
1
+ Write a caption for the diagram: what the reader is looking at, before they follow its lines. Two sentences at most.
2
+
3
+ - **The first sentence says what the diagram starts from.** Open with "This diagram shows how", name the page, the component, the job or the route the paths start at, and say what it does when it opens, loads or runs: `This diagram shows how the edit page loads an order and renders it in the form.` Use the verb of the code for what it does, such as renders, loads or requests, so that "shows" is not written twice.
4
+ - **The second sentence follows the user's actions.** The actions are the events on the diagram: a submit, a click, a pick, a typed value. Open with "It also shows what happens when the user", name the action as the user would, then say where its data ends up: the request it sends, the store it writes, the page it opens. `It also shows what happens when the user saves the order, and how the changed order reaches the API through updateOrder().`
5
+ - **Several actions.** Name them together, in the order the diagram draws them: `It also shows what happens when the user picks a customer, picks a product, types a quantity or submits the form.`
6
+ - **A path nobody clicks.** A request, a schedule or another system starts it: name that in place of the user. `It also shows what happens when a request reaches POST /orders, and how the order reaches the database.`
7
+ - **No action on the diagram.** Leave the second sentence out, and never write "It also shows" with nothing after it.
8
+ - **Shared code that other segments call.** Say what the diagram holds and what reaches it: `This diagram shows how the route table opens the order pages, and how each hook loads or sends orders through its request.`
9
+
10
+ Name where the data ends up, not the steps on the way: the labels and the descriptions of the nodes carry the steps, and the reader follows them on the board. Do not explain the change: the Context Section and the waypoints do.
11
+
12
+ | The diagram | Its caption |
13
+ |---|---|
14
+ | A page that loads a record and saves it | This diagram shows how the edit page loads an order and renders it in the form. It also shows what happens when the user saves the order, and how the changed order reaches the API through `updateOrder()`. |
15
+ | A page that creates a record | This diagram shows how the create page opens with an empty draft in the form. It also shows what happens when the user submits the form, and how the new order reaches the API through `createOrder()`. |
16
+ | A page with no action on its paths | This diagram shows how the orders list loads the orders and renders them in a table. |
@@ -0,0 +1,11 @@
1
+ Say what this row of the node does, as a reader of the product would. Start with a verb in the present tense: "Queries every Pokemon ordered by name", "Sends the order to the API". Read the code of the node first, so the label says what the block does, not what it is or what it is called: "Queries every Pokemon ordered by name", not "The query of every Pokemon".
2
+
3
+ - **An argument.** Say what the node does with the value it is given: `Filters the Pokemon by this trainer`, not `The trainer to filter by`.
4
+ - **A state.** Say what the node keeps in it: `Keeps the lines of the cart`, not `The lines of the cart`.
5
+ - **A hook.** Say what the node gets from it: `Gets the mutation that applies a promo code`.
6
+ - **An effect.** Say what it does and when: `Clears the form after a save`.
7
+ - **A call.** Say what is asked of the code it calls: `Saves the renamed user`.
8
+ - **A value.** Say what the code that makes it does: `Queries every Pokemon ordered by name`, not `The query of every Pokemon`.
9
+ - **A step.** Say what the step does: `Returns an error for an empty title`. For a condition, say what is checked: `Checks whether a trainer is given`. A step can stand for several statements that follow each other, listed by the first: say what they do together, `Renames the chosen user`.
10
+
11
+ Leave the name of the code out: the row shows it under your label. Keep the same shape and tense on every block label of one node: each one starts with a verb.
@@ -1,4 +1,4 @@
1
- Tell the journey that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
1
+ Tell the trace that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
2
2
 
3
3
  - **Several paths.** A node that more than one path reaches opens with one line that says so, then a list with one such sentence per path.
4
4
  - **A node with trigger labels.** Say what each event runs and what each fetch feeds, in the words of its trigger label: `When a shopper clicks "All", the handler calls setStatus(null) on the filter store.`
@@ -43,7 +43,7 @@ sort order, the option merge, the loop — unless that detail is the change itse
43
43
  change to the purpose `context` states, usually with _so that_ or _because_. A reviewer who reads
44
44
  only this card should know why it is in the pull request.
45
45
 
46
- **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blast` lists the files
46
+ **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blastDiagram` lists the files
47
47
  that import the file this card is in, and what the change does to each: its `impactType` and its `impactReason`. Name the one this card exists
48
48
  for — the form that no longer submits, the route that now returns something else, the caller that now
49
49
  depends on the new value — and link it. Where nothing outside the change reaches this code, name
@@ -1,70 +1,24 @@
1
- Write three parts, in this order: an opening paragraph, then `## Overview`, then
2
- `## Implementation`.
1
+ Write one or two sentences that start with "This segment" and say what the
2
+ segment's change does. That is the whole context. Flight Plan lists every piece
3
+ of code the segment adds, modifies and removes under it, in the Change Overview,
4
+ so the context holds no list of changes, no accordion and no code links.
3
5
 
4
6
  ```markdown
5
- A basket with an item that sold out a minute ago could still reach payment. The
6
- shopper now hears about every such item before paying.
7
-
8
- ## Overview
9
-
10
- - **When** a customer submits a basket with two lines out of stock, **then**
11
- [the error names both lines](code:src/stock/check.ts#hasStock).
12
- - **When** every line is in stock, **then** nothing changes.
13
-
14
- ## Implementation
15
-
16
- **`src/stock/`**
17
-
18
- - Modified [`hasStock()`](code:src/stock/check.ts#hasStock) to read every level
19
- once and collect every short line.
7
+ This segment checks the stock of every basket line before payment, so a basket
8
+ with an item that sold out a minute ago gets an error naming each sold-out item
9
+ and never reaches payment.
20
10
  ```
21
11
 
22
- **Verify every claim against the diff**, never against a pull request's own
12
+ Check every claim against the diff, never against the pull request's own
23
13
  description.
24
14
 
25
- ### The opening paragraph
26
-
27
- Say why anyone should care, to a reader who has not seen the code.
28
-
29
- **This paragraph bans identifiers, paths and links.** If you cannot write it
30
- without naming a symbol, you are describing the implementation rather than the
31
- change. That ban is what makes it the easiest place to hide a vague verb, so say
32
- what the reader would see: not "the size check handles an oversized query" but
33
- "a query over 1 MB now gets an error that names the 1 MB limit".
34
-
35
- Five sentences, and no more even when the change is large.
36
-
37
- ### Overview
38
-
39
- What changes from outside the code, as a list of scenarios. Each item is one
40
- sentence: a bold **When**, the situation, a bold **then**, what can be observed.
41
-
42
- The situation is in the reader's terms — one clause. Name what a person outside
43
- the code does, or the state that holds: "a customer submits a basket with two
44
- lines out of stock", "every line is in stock". Write the situation, not the code
45
- path that answers it.
46
-
47
- What can be observed is the result a person or another system sees, not the
48
- mechanism: "the error message names both out-of-stock lines". Link the code the
49
- result comes from where there is code to name.
50
-
51
- Say "nothing changes" when a reader would reasonably expect a change and there
52
- is none; that line stops a reviewer hunting for a regression that is not there.
53
- A "nothing changes" scenario carries no link.
54
-
55
- ### Implementation
56
-
57
- What changed inside the code, grouped by where it lives. Each group is a bold
58
- label on its own line, then a list of the changes there.
59
-
60
- The label is the place the changes live — a file, or a directory when several
61
- inside it are touched. It takes no verb. Group by where the code lives, not by
62
- theme, and put the groups in the order the tour walks them.
15
+ ### What the sentences say
63
16
 
64
- Each item is one change a reader would notice, as one sentence: the verb first,
65
- then the code it names. "Modified `hasStock()` to read every level once and
66
- collect every short line." Link the code the claim is about.
17
+ Say what the segment's change does for a reader who has not seen the code. Name
18
+ no identifiers, paths or links. Say what someone would see: "a query over 1 MB
19
+ now gets an error that names the limit" tells the reader more than "the size
20
+ check handles large queries".
67
21
 
68
- An item that names no code is usually one that has not been thought through. The
69
- exceptions are rare — a configuration value, a deleted file, the tests — and
70
- they carry no link.
22
+ Write about the files of this segment only. When the reviewer turned segments
23
+ off, the first segment's context is the one Context of the whole change: start
24
+ it with "This change" and say what the whole change does.
@@ -0,0 +1,16 @@
1
+ Write a caption for the diagram: what the reader is looking at, before they follow its lines. Two sentences at most.
2
+
3
+ - **The first sentence says what the diagram starts from.** Open with "This diagram shows how", name the page, the component, the job or the route the paths start at, and say what it does when it opens, loads or runs: `This diagram shows how the edit page loads an order and renders it in the form.` Use the verb of the code for what it does, such as renders, loads or requests, so that "shows" is not written twice.
4
+ - **The second sentence follows the user's actions.** The actions are the events on the diagram: a submit, a click, a pick, a typed value. Open with "It also shows what happens when the user", name the action as the user would, then say where its data ends up: the request it sends, the store it writes, the page it opens. `It also shows what happens when the user saves the order, and how the changed order reaches the API through updateOrder().`
5
+ - **Several actions.** Name them together, in the order the diagram draws them: `It also shows what happens when the user picks a customer, picks a product, types a quantity or submits the form.`
6
+ - **A path nobody clicks.** A request, a schedule or another system starts it: name that in place of the user. `It also shows what happens when a request reaches POST /orders, and how the order reaches the database.`
7
+ - **No action on the diagram.** Leave the second sentence out, and never write "It also shows" with nothing after it.
8
+ - **Shared code that other segments call.** Say what the diagram holds and what reaches it: `This diagram shows how the route table opens the order pages, and how each hook loads or sends orders through its request.`
9
+
10
+ Name where the data ends up, not the steps on the way: the labels and the descriptions of the nodes carry the steps, and the reader follows them on the board. Do not explain the change: the Context Section and the waypoints do.
11
+
12
+ | The diagram | Its caption |
13
+ |---|---|
14
+ | A page that loads a record and saves it | This diagram shows how the edit page loads an order and renders it in the form. It also shows what happens when the user saves the order, and how the changed order reaches the API through `updateOrder()`. |
15
+ | A page that creates a record | This diagram shows how the create page opens with an empty draft in the form. It also shows what happens when the user submits the form, and how the new order reaches the API through `createOrder()`. |
16
+ | A page with no action on its paths | This diagram shows how the orders list loads the orders and renders them in a table. |
@@ -0,0 +1,11 @@
1
+ Say what this row of the node does, as a reader of the product would. Start with a verb in the present tense: "Queries every Pokemon ordered by name", "Sends the order to the API". Read the code of the node first, so the label says what the block does, not what it is or what it is called: "Queries every Pokemon ordered by name", not "The query of every Pokemon".
2
+
3
+ - **An argument.** Say what the node does with the value it is given: `Filters the Pokemon by this trainer`, not `The trainer to filter by`.
4
+ - **A state.** Say what the node keeps in it: `Keeps the lines of the cart`, not `The lines of the cart`.
5
+ - **A hook.** Say what the node gets from it: `Gets the mutation that applies a promo code`.
6
+ - **An effect.** Say what it does and when: `Clears the form after a save`.
7
+ - **A call.** Say what is asked of the code it calls: `Saves the renamed user`.
8
+ - **A value.** Say what the code that makes it does: `Queries every Pokemon ordered by name`, not `The query of every Pokemon`.
9
+ - **A step.** Say what the step does: `Returns an error for an empty title`. For a condition, say what is checked: `Checks whether a trainer is given`. A step can stand for several statements that follow each other, listed by the first: say what they do together, `Renames the chosen user`.
10
+
11
+ Leave the name of the code out: the row shows it under your label. Keep the same shape and tense on every block label of one node: each one starts with a verb.
@@ -1,4 +1,4 @@
1
- Tell the journey that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
1
+ Tell the trace that reaches this node, in the order the diagram draws it: "When {who} {action}, {caller} {calls, renders or reads} this {what}." Start with what starts the path, then name each step between it and this node, and end on what hands over to it: `When a shopper opens /orders, <OrdersPage /> calls useOrders(status), and useOrders() hands this function to useQuery as its query function.`
2
2
 
3
3
  - **Several paths.** A node that more than one path reaches opens with one line that says so, then a list with one such sentence per path.
4
4
  - **A node with trigger labels.** Say what each event runs and what each fetch feeds, in the words of its trigger label: `When a shopper clicks "All", the handler calls setStatus(null) on the filter store.`
@@ -43,7 +43,7 @@ sort order, the option merge, the loop — unless that detail is the change itse
43
43
  change to the purpose `context` states, usually with _so that_ or _because_. A reviewer who reads
44
44
  only this card should know why it is in the pull request.
45
45
 
46
- **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blast` lists the files
46
+ **Take the connection from the Blast Diagram, not from a guess.** Where the artifact has one, `blastDiagram` lists the files
47
47
  that import the file this card is in, and what the change does to each: its `impactType` and its `impactReason`. Name the one this card exists
48
48
  for — the form that no longer submits, the route that now returns something else, the caller that now
49
49
  depends on the new value — and link it. Where nothing outside the change reaches this code, name