the-frame-ai 0.11.2 → 0.11.3
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/package.json +1 -1
- package/src/update.js +4 -6
- package/templates/commands/frame:perf-fix.md +22 -21
package/package.json
CHANGED
package/src/update.js
CHANGED
|
@@ -53,13 +53,11 @@ export async function update(target, flags = {}) {
|
|
|
53
53
|
|
|
54
54
|
// Ask frontend question early, before file operations
|
|
55
55
|
let frontendDecided = config.frontend === true;
|
|
56
|
-
if (
|
|
56
|
+
if (config.frontend === undefined && !flags.yes) {
|
|
57
57
|
const frontend = await promptFrontend(false);
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
writeFileSync(join(target, '.frame', 'config.json'), JSON.stringify(config, null, 2), 'utf-8');
|
|
62
|
-
}
|
|
58
|
+
config.frontend = frontend;
|
|
59
|
+
frontendDecided = frontend;
|
|
60
|
+
writeFileSync(join(target, '.frame', 'config.json'), JSON.stringify(config, null, 2), 'utf-8');
|
|
63
61
|
}
|
|
64
62
|
|
|
65
63
|
let updated = 0;
|
|
@@ -37,45 +37,46 @@ Parse issues based on `$ARGUMENTS`:
|
|
|
37
37
|
|
|
38
38
|
Output: "Found {N} issues to fix: {list of IDs and titles}."
|
|
39
39
|
|
|
40
|
-
### Step 2:
|
|
40
|
+
### Step 2: Group Issues into Waves
|
|
41
41
|
|
|
42
|
-
|
|
42
|
+
Before applying any fixes, analyze all issues and group them into waves:
|
|
43
43
|
|
|
44
|
-
1
|
|
45
|
-
2
|
|
46
|
-
|
|
44
|
+
- **Wave 1**: issues in different files with no shared dependencies — apply all in this wave
|
|
45
|
+
- **Wave 2**: issues that depend on Wave 1 changes (same module, shared types, etc.)
|
|
46
|
+
- **Wave N**: remaining issues
|
|
47
47
|
|
|
48
|
-
Output
|
|
48
|
+
Output:
|
|
49
|
+
```
|
|
50
|
+
Wave 1 ({N} issues — independent): PERF-1, PERF-3, PERF-5
|
|
51
|
+
Wave 2 ({N} issues — depend on wave 1): PERF-2, PERF-4
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Step 3: Apply Wave by Wave
|
|
49
55
|
|
|
56
|
+
For each wave:
|
|
57
|
+
|
|
58
|
+
1. Apply all fixes in the wave (read file → apply change for each issue)
|
|
59
|
+
2. Output before each fix:
|
|
50
60
|
```
|
|
51
61
|
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
52
62
|
[PERF-1] {title}
|
|
53
63
|
File: path/file.ts:42
|
|
54
|
-
Applying
|
|
64
|
+
Applying: {1 sentence}
|
|
55
65
|
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
|
56
66
|
```
|
|
57
|
-
|
|
58
|
-
### Step 3: Apply Fix
|
|
59
|
-
|
|
60
|
-
1. Apply the code change to the file
|
|
61
|
-
2. Run type check if available:
|
|
67
|
+
3. After all fixes in the wave, run typecheck + tests once:
|
|
62
68
|
```bash
|
|
63
69
|
{quality.commands.typecheck} 2>&1 | tail -10
|
|
64
|
-
```
|
|
65
|
-
3. Run tests if available:
|
|
66
|
-
```bash
|
|
67
70
|
{quality.commands.test} 2>&1 | tail -20
|
|
68
71
|
```
|
|
69
72
|
|
|
70
|
-
If typecheck or tests fail → revert
|
|
71
|
-
|
|
72
|
-
Output: "✓ [PERF-1] fixed. {brief description of what changed}."
|
|
73
|
+
If typecheck or tests fail → revert all fixes from this wave, report what broke, ask user how to proceed. Then continue to next wave.
|
|
73
74
|
|
|
74
|
-
|
|
75
|
+
Output after wave: "✓ Wave {N} complete: {list of fixed IDs}."
|
|
75
76
|
|
|
76
|
-
|
|
77
|
+
### Step 4: Summary
|
|
77
78
|
|
|
78
|
-
After all
|
|
79
|
+
After all waves processed, output summary:
|
|
79
80
|
```
|
|
80
81
|
Performance fixes complete.
|
|
81
82
|
Fixed: {N} | Skipped: {N}
|