foldkit 0.112.5 → 0.113.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.
@@ -37,9 +37,11 @@ export declare const composeBoundary: (parent: BoundaryId, childId: string) => B
37
37
  * `beginRender`. Boundaries behind a `createLazy`/`createKeyedLazy`
38
38
  * cache hit are replayed into this map via {@link markSeenForLazyHit}
39
39
  * so the duplicate-slotId guard catches collisions against memoized
40
- * siblings, not just against siblings that re-ran this frame. It is
41
- * NOT used for pruning; pruning is driven by VNode destroy hooks
42
- * instead.
40
+ * siblings, not just against siblings that re-ran this frame. It does
41
+ * not drive pruning (VNode destroy hooks do), but the Submodel destroy
42
+ * hook reads it during the patch phase to tell a same-cycle remount (a
43
+ * keyed root whose key changed) from a true unmount, skipping
44
+ * deregistration in the remount case. See {@link beginRender}.
43
45
  *
44
46
  * `lazyTrackingStack` is a stack of sets used by `createLazy` and
45
47
  * `createKeyedLazy` to capture which boundary ids were marked alive
@@ -1 +1 @@
1
- {"version":3,"file":"boundary.d.ts","sourceRoot":"","sources":["../../src/html/boundary.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAA;AAEzD,wDAAwD;AACxD,MAAM,MAAM,cAAc,GAAG,QAAQ,CAAC;IACpC,eAAe,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,CAAA;CAC/C,CAAC,CAAA;AAEF;;;;eAIe;AACf,MAAM,MAAM,UAAU,GAAG,MAAM,CAAA;AAI/B,eAAO,MAAM,aAAa,EAAE,UAAe,CAAA;AAE3C,eAAO,MAAM,eAAe,GAC1B,QAAQ,UAAU,EAClB,SAAS,MAAM,KACd,UAUF,CAAA;AAKD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;aAsCa;AACb,MAAM,MAAM,gBAAgB,GAAG;IAC7B,QAAQ,CAAC,KAAK,EAAE,GAAG,CAAC,UAAU,EAAE,cAAc,CA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AA;AAED;;;;;;;;;gBASgB;AAChB,eAAO,MAAM,sBAAsB,GACjC,UAAU,gBAAgB,EAC1B,YAAY,UAAU,KACrB,IAEF,CAAA;AA8CD,eAAO,MAAM,2BAA2B,GACtC,UAAU,gBAAgB,EAC1B,eAAe,YAAY,EAC3B,YAAY,UAAU,KACrB,YAkBF,CAAA;AAED;;;;;;;;;;iEAUiE;AACjE,eAAO,MAAM,WAAW,GAAI,UAAU,gBAAgB,KAAG,IAExD,CAAA"}
@@ -43,7 +43,7 @@ const defaultSlowViewCallback = (context) => {
43
43
  return tag;
44
44
  },
45
45
  });
46
- console.warn(`[foldkit] Slow view: ${context.durationMs.toFixed(1)}ms (budget: ${context.thresholdMs}ms), triggered by ${trigger}. Consider moving computation to update or memoizing with createLazy.`, ...Option.toArray(context.message));
46
+ console.warn(`[foldkit] Slow view: ${context.durationMs.toFixed(1)}ms (budget: ${context.thresholdMs}ms), triggered by ${trigger}. Memoize expensive subtrees with createLazy. Cache derived data on the model in update only when memoization cannot cover it, since every update branch then has to keep it in sync.`, ...Option.toArray(context.message));
47
47
  };
48
48
  /** Effect service tag that provides message dispatching to the view layer. */
49
49
  export class Dispatch extends Context.Service()('@foldkit/Dispatch') {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "foldkit",
3
- "version": "0.112.5",
3
+ "version": "0.113.0",
4
4
  "description": "A TypeScript frontend framework, built on Effect and architected like Elm",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -129,18 +129,18 @@
129
129
  "dist"
130
130
  ],
131
131
  "peerDependencies": {
132
- "@effect/platform-browser": "4.0.0-beta.78",
133
- "effect": "4.0.0-beta.78"
132
+ "@effect/platform-browser": "4.0.0-beta.83",
133
+ "effect": "4.0.0-beta.83"
134
134
  },
135
135
  "devDependencies": {
136
- "@effect/platform-browser": "4.0.0-beta.78",
137
- "@effect/vitest": "4.0.0-beta.78",
138
- "effect": "4.0.0-beta.78",
139
- "happy-dom": "^20.9.0",
136
+ "@effect/platform-browser": "4.0.0-beta.83",
137
+ "@effect/vitest": "4.0.0-beta.83",
138
+ "effect": "4.0.0-beta.83",
139
+ "happy-dom": "^20.10.4",
140
140
  "rimraf": "^6.1.3",
141
141
  "typedoc": "^0.28.19",
142
142
  "typescript": "^6.0.3",
143
- "vitest": "^4.1.5"
143
+ "vitest": "^4.1.9"
144
144
  },
145
145
  "keywords": [
146
146
  "effect",