@octanejs/tanstack-db 0.0.7 → 0.0.8

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@octanejs/tanstack-db",
3
- "version": "0.0.7",
3
+ "version": "0.0.8",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "engines": {
@@ -47,12 +47,12 @@
47
47
  "@tanstack/db": "^0.7.0"
48
48
  },
49
49
  "peerDependencies": {
50
- "octane": "0.1.44"
50
+ "octane": "0.1.45"
51
51
  },
52
52
  "devDependencies": {
53
53
  "vitest": "^4.1.10",
54
- "@octanejs/testing-library": "0.1.41",
55
- "octane": "0.1.44"
54
+ "@octanejs/testing-library": "0.1.42",
55
+ "octane": "0.1.45"
56
56
  },
57
57
  "scripts": {
58
58
  "test": "vitest run"
@@ -221,14 +221,12 @@ export function useLiveSuspenseQuery(configOrQueryOrCollection: any, ...rest: Ar
221
221
  throw new Error(`Collection "${result.collection.id}" failed to load`);
222
222
  }
223
223
 
224
- // OCTANE DIVERGENCE: suspend via `use(thenable)`, not `throw promise`, and call
224
+ // OCTANE ADAPTATION: consume the preload promise through `use(thenable)`, and call
225
225
  // `use()` UNCONDITIONALLY — exactly once on every path that keeps rendering.
226
226
  //
227
- // Upstream react-db `throw`s the preload promise, and a React `throw` suspends
228
- // the whole component with no positional state. Octane Suspense instead only
229
- // recognizes the sentinel `use()` produces (a raw thrown promise reaches the
230
- // error path and never renders the fallback), and Octane tracks `use(thenable)`
231
- // by dynamic call-order index (the runtime's `__thenableIdx`), like React's
227
+ // Upstream react-db throws the preload promise; Octane supports that too.
228
+ // This binding uses the public hook, whose thenable state is tracked by
229
+ // dynamic call-order index (the runtime's `__thenableIdx`), like React's
232
230
  // positional `thenableState` — NOT by compiler slot. So skipping `use()` on the
233
231
  // ready / stale-after-error paths would shift the thenable index of any sibling
234
232
  // `use()` or second `useLiveSuspenseQuery` in the same component, which could