Skip to content

Commit a4d829b

Browse files
committed
docs: close tree-shaking pipeline split plan
1 parent 1a89387 commit a4d829b

1 file changed

Lines changed: 11 additions & 9 deletions

File tree

docs/superpowers/plans/2026-05-08-qraft-tree-shaking-pipeline-split.md

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
- Create: `packages/tree-shaking-plugin/src/lib/transform/plan.ts`
1818
- Modify: `packages/tree-shaking-plugin/src/core.test.ts`
1919

20-
- [ ] **Step 1: Add a planner test that fails before the new module exists**
20+
- [x] **Step 1: Add a planner test that fails before the new module exists**
2121

2222
```ts
2323
import { createTransformPlan } from './lib/transform/plan.js';
@@ -46,7 +46,7 @@ export function App() {
4646
});
4747
```
4848

49-
- [ ] **Step 2: Run the targeted test and confirm the planner is missing**
49+
- [x] **Step 2: Run the targeted test and confirm the planner is missing**
5050

5151
Run:
5252

@@ -56,7 +56,7 @@ yarn workspace @openapi-qraft/tree-shaking-plugin test -- src/core.test.ts -t "c
5656

5757
Expected: FAIL because `createTransformPlan` and the shared plan types do not exist yet.
5858

59-
- [ ] **Step 3: Add the shared plan types and the planner implementation**
59+
- [x] **Step 3: Add the shared plan types and the planner implementation**
6060

6161
Use this shape for the new boundary:
6262

@@ -82,7 +82,7 @@ export async function createTransformPlan(
8282

8383
Keep the planner responsible for discovery, resolution, and bookkeeping only. Do not move source-map composition or path rendering into this spec.
8484

85-
- [ ] **Step 4: Re-run the targeted test and confirm the new boundary is real**
85+
- [x] **Step 4: Re-run the targeted test and confirm the new boundary is real**
8686

8787
Run:
8888

@@ -99,7 +99,7 @@ Expected: PASS.
9999
- Modify: `packages/tree-shaking-plugin/src/core.ts`
100100
- Modify: `packages/tree-shaking-plugin/src/core.test.ts`
101101

102-
- [ ] **Step 1: Add a regression snapshot that exercises the public transform after the refactor**
102+
- [x] **Step 1: Add a regression snapshot that exercises the public transform after the refactor**
103103

104104
Keep one representative snapshot in `core.test.ts` that still proves the emitted tree-shaking output is unchanged for a named client.
105105

@@ -118,7 +118,7 @@ expect(result?.code).toMatchInlineSnapshot(`
118118
`);
119119
```
120120

121-
- [ ] **Step 2: Move the write path into `applyTransformPlan` and keep `core.ts` as orchestration only**
121+
- [x] **Step 2: Move the write path into `applyTransformPlan` and keep `core.ts` as orchestration only**
122122

123123
Use this mutator boundary:
124124

@@ -131,7 +131,7 @@ export function applyTransformPlan(
131131

132132
`src/core.ts` should parse, build a plan, apply it, and generate code. The AST write path belongs in `mutate.ts`, not in `core.ts`.
133133

134-
- [ ] **Step 3: Run the package unit suite and typecheck**
134+
- [x] **Step 3: Run the package unit suite and typecheck**
135135

136136
Run:
137137

@@ -142,7 +142,7 @@ yarn workspace @openapi-qraft/tree-shaking-plugin typecheck
142142

143143
Expected: both commands pass with the refactor in place.
144144

145-
- [ ] **Step 4: Run the external tree-shaking e2e checkpoint**
145+
- [x] **Step 4: Run the external tree-shaking e2e checkpoint**
146146

147147
Run:
148148

@@ -152,11 +152,13 @@ cd e2e && yarn e2e:tree-shaking-bundlers-local
152152

153153
Expected: the local multi-bundler fixture still publishes, updates, builds, and unpublishes cleanly with the same emitted contract.
154154

155-
- [ ] **Step 5: Commit the split**
155+
- [x] **Step 5: Commit the split**
156156

157157
```bash
158158
git add packages/tree-shaking-plugin/src/lib/transform/types.ts packages/tree-shaking-plugin/src/lib/transform/plan.ts packages/tree-shaking-plugin/src/lib/transform/mutate.ts packages/tree-shaking-plugin/src/core.ts packages/tree-shaking-plugin/src/core.test.ts
159159
git commit -m "refactor: split tree-shaking pipeline"
160160
```
161161

162162
---
163+
164+
**Status:** completed and validated with package `lint`, `test`, `typecheck`, and external `e2e:tree-shaking-bundlers-local`.

0 commit comments

Comments
 (0)