@xh/hoist 88.1.0 → 88.1.1
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/CHANGELOG.md
CHANGED
|
@@ -12,6 +12,16 @@
|
|
|
12
12
|
3. Plain ASCII punctuation only. Use " - " for in-sentence breaks, never an em dash.
|
|
13
13
|
-->
|
|
14
14
|
|
|
15
|
+
## 88.1.1 - 2026-10-06
|
|
16
|
+
|
|
17
|
+
### 🤖 AI Docs + Tooling
|
|
18
|
+
|
|
19
|
+
* Fixed the `@persist` ordering check in the v88 upgrade notes. It missed the stacked
|
|
20
|
+
`@persist.with({...})` form and flagged fields that were already in the correct order. The check
|
|
21
|
+
for removed `*Col` aliases now matches whole words only.
|
|
22
|
+
* Added a step to the v88 upgrade notes to restart the hoist-react MCP server after installing v88.
|
|
23
|
+
* The v88 codemods now print file paths relative to the working directory.
|
|
24
|
+
|
|
15
25
|
## 88.1.0 - 2026-10-01
|
|
16
26
|
|
|
17
27
|
### 🎁 New Features
|
|
@@ -139,6 +139,6 @@ async function processFile(filePath) {
|
|
|
139
139
|
formACount += localFormA;
|
|
140
140
|
formBCount += localFormB;
|
|
141
141
|
if (!DRY) await fs.writeFile(filePath, content);
|
|
142
|
-
console.log(` ${path.relative(
|
|
142
|
+
console.log(` ${path.relative(process.cwd(), filePath)} — form A=${localFormA}, form B=${localFormB}`);
|
|
143
143
|
}
|
|
144
144
|
}
|
|
@@ -127,13 +127,13 @@ async function processFile(filePath) {
|
|
|
127
127
|
`import {${names.join(', ')}} from '${m[2]}';` +
|
|
128
128
|
content.slice(m.index + m[0].length);
|
|
129
129
|
} else if (Object.values(RENAMES).some(to => new RegExp(`\\b${to}\\b`).test(content))) {
|
|
130
|
-
console.log(` WARN no mobx import found to update: ${path.relative(
|
|
130
|
+
console.log(` WARN no mobx import found to update: ${path.relative(process.cwd(), filePath)}`);
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
filesChanged++;
|
|
134
134
|
renameCount += localCount;
|
|
135
135
|
if (!DRY) await fs.writeFile(filePath, content);
|
|
136
|
-
console.log(` ${path.relative(
|
|
136
|
+
console.log(` ${path.relative(process.cwd(), filePath)} — ${localCount} renamed`);
|
|
137
137
|
}
|
|
138
138
|
|
|
139
139
|
/** Move names imported from 'mobx' onto '@xh/hoist/mobx', merging into an existing Hoist import. */
|
|
@@ -157,7 +157,7 @@ function redirectMobxImport(content, filePath) {
|
|
|
157
157
|
if (kept.length) {
|
|
158
158
|
console.log(
|
|
159
159
|
` WARN not re-exported by @xh/hoist/mobx, left on 'mobx': ${kept.join(', ')} ` +
|
|
160
|
-
`(${path.relative(
|
|
160
|
+
`(${path.relative(process.cwd(), filePath)})`
|
|
161
161
|
);
|
|
162
162
|
}
|
|
163
163
|
if (!moved.length) {
|
|
@@ -128,7 +128,7 @@ async function processFile(filePath) {
|
|
|
128
128
|
importsTrimmed += trimmedImports;
|
|
129
129
|
if (!DRY) await fs.writeFile(filePath, modified);
|
|
130
130
|
console.log(
|
|
131
|
-
` ${path.relative(
|
|
131
|
+
` ${path.relative(process.cwd(), filePath)} — calls=${removedCalls}, ctors=${removedConstructors}, imports=${trimmedImports}`
|
|
132
132
|
);
|
|
133
133
|
}
|
|
134
134
|
}
|
|
@@ -214,6 +214,11 @@ in-place upgrade can leave older copies of packages that Hoist now requires at a
|
|
|
214
214
|
`@codemirror/state` and `@codemirror/view` in particular - and `tsc` then fails inside Hoist's
|
|
215
215
|
`CodeInput` with conflicting types.
|
|
216
216
|
|
|
217
|
+
If an AI agent runs the upgrade with the hoist-react MCP server, restart the server now. In Claude
|
|
218
|
+
Code, reconnect with `/mcp` or restart the session. The server reads the installed `@xh/hoist`
|
|
219
|
+
version only when it starts, so until then it answers with v87 docs and types. The `hoist-docs`
|
|
220
|
+
and `hoist-ts` CLI tools read the installed version on each call and need no restart.
|
|
221
|
+
|
|
217
222
|
See the [dev-utils migration guide](https://github.com/xh/hoist-dev-utils/blob/develop/README.md#migrating-from-v15-webpack)
|
|
218
223
|
for the full option reference, and Toolbox's
|
|
219
224
|
[`rsbuild.config.mjs`](https://github.com/xh/toolbox/blob/develop/client-app/rsbuild.config.mjs)
|
|
@@ -321,19 +326,33 @@ codemods do not reorder decorators, and a reversed pair fails silently: `Persist
|
|
|
321
326
|
logs an error to the console and the field simply stops persisting, with no type error.
|
|
322
327
|
|
|
323
328
|
```bash
|
|
324
|
-
|
|
329
|
+
# Reversed on one line: `@persist @bindable ...`, `@persist.with({...}) @observable ...`
|
|
330
|
+
grep -rnE '@persist(\.with\(.*\))?\s+@(bindable|observable)' client-app/src/
|
|
331
|
+
|
|
332
|
+
# Reversed across lines: prints the MobX decorator line under a leading `@persist`
|
|
333
|
+
grep -rnE -A1 '^\s*@persist(\.with\(.*\))?\s*(//.*)?$' client-app/src/ | grep -E '^\S+-[0-9]+-\s*@(bindable|observable)'
|
|
325
334
|
```
|
|
326
335
|
|
|
336
|
+
The stacked form, with `@persist.with({...})` on its own line above `@bindable`, is easy to miss
|
|
337
|
+
in review. The second command finds it.
|
|
338
|
+
|
|
327
339
|
Before:
|
|
328
340
|
|
|
329
341
|
```typescript
|
|
330
342
|
@persist @bindable accessor showInactive = false;
|
|
343
|
+
|
|
344
|
+
@persist.with({path: 'gridState'})
|
|
345
|
+
@bindable accessor gridState = null;
|
|
331
346
|
```
|
|
332
347
|
|
|
333
348
|
After:
|
|
334
349
|
|
|
335
350
|
```typescript
|
|
336
351
|
@bindable @persist accessor showInactive = false;
|
|
352
|
+
|
|
353
|
+
@bindable
|
|
354
|
+
@persist.with({path: 'gridState'})
|
|
355
|
+
accessor gridState = null;
|
|
337
356
|
```
|
|
338
357
|
|
|
339
358
|
**Audit enumeration of model instances.** `accessor` fields are prototype getter/setters, not own
|
|
@@ -457,7 +476,7 @@ All of these were deprecated in v86 or earlier. Search for each and replace as s
|
|
|
457
476
|
|
|
458
477
|
```bash
|
|
459
478
|
grep -rn "withSpan\|mergePersistOptions\|PopoverFilterChooser\|LogSource" client-app/src/
|
|
460
|
-
grep -
|
|
479
|
+
grep -rnw "boolCheckCol\|numberCol\|fileExtCol\|dateCol\|timeCol\|dateTimeCol\|compactDateCol\|localDateCol" client-app/src/
|
|
461
480
|
grep -rn -A4 "XH.fetch" client-app/src/ | grep "span:\|loadSpec:"
|
|
462
481
|
```
|
|
463
482
|
|
|
@@ -574,8 +593,8 @@ After completing all steps:
|
|
|
574
593
|
- [ ] `pnpm lint` / `yarn lint` / `npm run lint` passes (or only pre-existing warnings remain)
|
|
575
594
|
- [ ] `grep -rn "makeObservable\|experimentalDecorators" client-app/src client-app/tsconfig.json`
|
|
576
595
|
returns nothing
|
|
577
|
-
- [ ] `
|
|
578
|
-
|
|
596
|
+
- [ ] Both `@persist` ordering greps from Step 4 return nothing (`@persist` comes after the MobX
|
|
597
|
+
decorator, on one line or stacked)
|
|
579
598
|
- [ ] Dev server starts with `rsbuild dev`; production build succeeds and CI passes its version
|
|
580
599
|
and build tag through `XH_APP_VERSION` / `XH_APP_BUILD`
|
|
581
600
|
- [ ] Application loads without console errors, including no AG Grid theme-conflict warning
|