@wcstack/devtools 1.29.0 → 1.30.0
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/dist/auto.min.js +1 -1
- package/dist/auto.min.js.map +1 -1
- package/dist/index.d.ts +10 -2
- package/dist/index.esm.js +15 -6
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -65,6 +65,14 @@ interface IStateElementSummaryLike {
|
|
|
65
65
|
* 旧ランタイムにはフィールド自体が無いため optional。宣言なしは null。
|
|
66
66
|
*/
|
|
67
67
|
readonly watchPaths?: ReadonlySet<string> | null;
|
|
68
|
+
/**
|
|
69
|
+
* `$listKeys` で宣言されたリストパス集合(protocol v1 追補)。ワイルドカード行
|
|
70
|
+
* watch に**リスト書き込み**が届く前提は「for バインド(paths.list)or
|
|
71
|
+
* $listKeys 宣言」なので、前提判定の正確化に paths.list と対で使う
|
|
72
|
+
*(明示 index 書き込みは前提に依らず発火し得る)。旧ランタイムにはフィールド自体が
|
|
73
|
+
* 無いため optional(undefined = $listKeys 側が観測不能)。宣言なしは null。
|
|
74
|
+
*/
|
|
75
|
+
readonly keyedListPaths?: ReadonlySet<string> | null;
|
|
68
76
|
}
|
|
69
77
|
/**
|
|
70
78
|
* 宣言レベルのバインディング 1 件(getDeclaredBindings の要素・protocol v1 追補)。
|
|
@@ -249,8 +257,8 @@ type CoreChangeListener = (kind: CoreChangeKind) => void;
|
|
|
249
257
|
/**
|
|
250
258
|
* 配線カバレッジ 1 行(static-wiring-dx-design.md §4 — 宣言 × 実測の突合)。
|
|
251
259
|
* - watch: `fired`(count 回)/ `never` / `prerequisite-missing`
|
|
252
|
-
* (ワイルドカード行 watch
|
|
253
|
-
*
|
|
260
|
+
* (ワイルドカード行 watch は「for バインド or $listKeys 宣言」が無いと
|
|
261
|
+
* リスト書き込みが行へ届かない — 「未発火」と区別しないと誤警告になる)
|
|
254
262
|
* - command / eventToken: `emitted`(count 回)/ `never` /
|
|
255
263
|
* `emitted-unheard`(全 emit が subscriberCount 0 = 空撃ち。§4 の突合対象)
|
|
256
264
|
* - binding: canonical declared がある場合のみ。`attached` / `never-attached`
|
package/dist/index.esm.js
CHANGED
|
@@ -452,14 +452,21 @@ class DevtoolsCore {
|
|
|
452
452
|
out.push({ stateName: entry.name, kind: "watch", name: path, status: "fired", count, note: null });
|
|
453
453
|
continue;
|
|
454
454
|
}
|
|
455
|
-
// ワイルドカード行 watch
|
|
456
|
-
//
|
|
457
|
-
//
|
|
458
|
-
//
|
|
455
|
+
// ワイルドカード行 watch に**リスト書き込み**が届く前提 = 各 `.*` 階層の
|
|
456
|
+
// リストが「for バインド(paths.list)or `$listKeys` 宣言(keyedListPaths)」
|
|
457
|
+
// されていること(watch 設計 §6-3)。未成立は「未発火」と区別する。
|
|
458
|
+
// 前提はリスト置換経路に限る主張 — 明示 index 書き込み(`$resolve` /
|
|
459
|
+
// `items.0.price` 代入。$getAll で listIndex 台帳が生えた後)は前提に
|
|
460
|
+
// 依らず発火し得るため、「一度も発火しない」とは断定できない(実測済み)。
|
|
461
|
+
// keyedListPaths は protocol v1 追補 — フィールドを持たない旧ランタイム
|
|
462
|
+
// では $listKeys 側が観測できないため、note はさらに観測形に落とす 2 段。
|
|
463
|
+
const keyedKnown = summary.keyedListPaths !== undefined;
|
|
459
464
|
let missingList = null;
|
|
460
465
|
for (let star = path.indexOf(".*"); star !== -1; star = path.indexOf(".*", star + 2)) {
|
|
461
466
|
const listPath = path.slice(0, star);
|
|
462
|
-
|
|
467
|
+
const satisfied = summary.paths.list.has(listPath)
|
|
468
|
+
|| (summary.keyedListPaths?.has(listPath) ?? false);
|
|
469
|
+
if (!satisfied) {
|
|
463
470
|
missingList = listPath;
|
|
464
471
|
break;
|
|
465
472
|
}
|
|
@@ -467,7 +474,9 @@ class DevtoolsCore {
|
|
|
467
474
|
if (missingList !== null) {
|
|
468
475
|
out.push({
|
|
469
476
|
stateName: entry.name, kind: "watch", name: path, status: "prerequisite-missing", count: 0,
|
|
470
|
-
note:
|
|
477
|
+
note: keyedKnown
|
|
478
|
+
? `list "${missingList}" has no for binding and no $listKeys declaration — list writes never reach its rows (only explicit-index writes can fire this watch)`
|
|
479
|
+
: `no for binding observed for list "${missingList}" (a $listKeys declaration would still let list writes fire it)`,
|
|
471
480
|
});
|
|
472
481
|
continue;
|
|
473
482
|
}
|