Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .changeset/eighty-ideas-clean.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/fix-like-ilike-on-demand-mode.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/fix-optimistic-state-in-synced-data.md

This file was deleted.

32 changes: 0 additions & 32 deletions .changeset/fix-progressive-mode-fetchsnapshot.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/improve-from-clause-error-messages.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/migrate-to-pacer-lite.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/warm-preload-on-demand.md

This file was deleted.

4 changes: 2 additions & 2 deletions examples/react/offline-transactions/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
},
"dependencies": {
"@tanstack/offline-transactions": ">=1.0.0",
"@tanstack/query-db-collection": ">=1.0.2",
"@tanstack/react-db": ">=0.1.47",
"@tanstack/query-db-collection": ">=1.0.3",
"@tanstack/react-db": ">=0.1.48",
"@tanstack/react-query": "^5.90.10",
"@tanstack/react-router": "^1.136.8",
"@tanstack/react-router-devtools": "^1.136.8",
Expand Down
4 changes: 2 additions & 2 deletions examples/react/projects/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
"dependencies": {
"@tailwindcss/vite": "^4.1.17",
"@tanstack/query-core": "^5.90.10",
"@tanstack/query-db-collection": ">=1.0.2",
"@tanstack/react-db": ">=0.1.47",
"@tanstack/query-db-collection": ">=1.0.3",
"@tanstack/react-db": ">=0.1.48",
"@tanstack/react-router": "^1.136.8",
"@tanstack/react-router-devtools": "^1.136.8",
"@tanstack/react-router-with-query": "^1.130.17",
Expand Down
7 changes: 7 additions & 0 deletions packages/angular-db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/angular-db

## 0.1.30

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.29

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/angular-db/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/angular-db",
"description": "Angular integration for @tanstack/db",
"version": "0.1.29",
"version": "0.1.30",
"author": "Ethan McDaniel",
"license": "MIT",
"repository": {
Expand Down
33 changes: 33 additions & 0 deletions packages/db-collection-e2e/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
# @tanstack/db-collection-e2e

## 0.0.6

### Patch Changes

- Fix progressive mode to use fetchSnapshot and atomic swap ([#852](https://github.com/TanStack/db/pull/852))

Progressive mode was broken because `requestSnapshot()` injected snapshots into the stream in causally correct position, which didn't work properly with the `full` mode stream. This release fixes progressive mode by:

**Core Changes:**
- Use `fetchSnapshot()` during initial sync to fetch and apply snapshots immediately in sync transactions
- Buffer all stream messages during initial sync (renamed flag to `isBufferingInitialSync`)
- Perform atomic swap on first `up-to-date`: truncate snapshot data → apply buffered messages → mark ready
- Track txids/snapshots only after atomic swap (enables correct optimistic transaction confirmation)

**Test Infrastructure:**
- Added `ELECTRIC_TEST_HOOKS` symbol for test control (hidden from public API)
- Added `progressiveTestControl.releaseInitialSync()` to E2E test config for explicit transition control
- Created comprehensive progressive mode E2E test suite (8 tests):
- Explicit snapshot phase and atomic swap validation
- Txid tracking behavior (Electric-only)
- Multiple concurrent snapshots with deduplication
- Incremental updates after swap
- Predicate handling and resilience tests

**Bug Fixes:**
- Fixed type errors in test files
- All 166 unit tests + 95 E2E tests passing

- Updated dependencies [[`f66f2cf`](https://github.com/TanStack/db/commit/f66f2cf944bbcc1a34ad7e340de2e78f5e27e666), [`e657a7d`](https://github.com/TanStack/db/commit/e657a7dad71dff6fb3dd24c2824f5b86d9f92cd5), [`f15b2a7`](https://github.com/TanStack/db/commit/f15b2a7081a2a21bd23ba3657fac44fc9c2f39a8), [`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/query-db-collection@1.0.3
- @tanstack/electric-db-collection@0.2.4
- @tanstack/db@0.5.4

## 0.0.5

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/db-collection-e2e/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@tanstack/db-collection-e2e",
"version": "0.0.5",
"version": "0.0.6",
"private": true,
"description": "End-to-end test suite for TanStack DB collections",
"type": "module",
Expand Down
34 changes: 34 additions & 0 deletions packages/db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,39 @@
# @tanstack/db

## 0.5.4

### Patch Changes

- Fix progressive mode to use fetchSnapshot and atomic swap ([#852](https://github.com/TanStack/db/pull/852))

Progressive mode was broken because `requestSnapshot()` injected snapshots into the stream in causally correct position, which didn't work properly with the `full` mode stream. This release fixes progressive mode by:

**Core Changes:**
- Use `fetchSnapshot()` during initial sync to fetch and apply snapshots immediately in sync transactions
- Buffer all stream messages during initial sync (renamed flag to `isBufferingInitialSync`)
- Perform atomic swap on first `up-to-date`: truncate snapshot data → apply buffered messages → mark ready
- Track txids/snapshots only after atomic swap (enables correct optimistic transaction confirmation)

**Test Infrastructure:**
- Added `ELECTRIC_TEST_HOOKS` symbol for test control (hidden from public API)
- Added `progressiveTestControl.releaseInitialSync()` to E2E test config for explicit transition control
- Created comprehensive progressive mode E2E test suite (8 tests):
- Explicit snapshot phase and atomic swap validation
- Txid tracking behavior (Electric-only)
- Multiple concurrent snapshots with deduplication
- Incremental updates after swap
- Predicate handling and resilience tests

**Bug Fixes:**
- Fixed type errors in test files
- All 166 unit tests + 95 E2E tests passing

- Improved error messages when invalid source types are passed to `.from()` or `.join()` methods. When users mistakenly pass a string, null, array, or other invalid type instead of an object with a collection, they now receive a clear, actionable error message with an example of the correct usage (e.g., `.from({ todos: todosCollection })`). ([#875](https://github.com/TanStack/db/pull/875))

- Migrated paced mutations implementation from `@tanstack/pacer` to `@tanstack/pacer-lite`. The lite version provides the same core functionality with minimal overhead and no external dependencies, making it more suitable for library use. This is an internal implementation change with no impact on the public API - all paced mutation strategies (debounce, throttle, queue) continue to work exactly as before. ([#880](https://github.com/TanStack/db/pull/880))

- Add warning when calling `.preload()` on collections with `on-demand` syncMode. In on-demand mode, data is only loaded when queries request it, so calling `.preload()` on the collection itself is a no-op. Users should create a live query and call `.preload()` on that instead. ([#871](https://github.com/TanStack/db/pull/871))

## 0.5.3

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/db/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/db",
"description": "A reactive client store for building super fast apps on sync",
"version": "0.5.3",
"version": "0.5.4",
"dependencies": {
"@standard-schema/spec": "^1.0.0",
"@tanstack/db-ivm": "workspace:*",
Expand Down
33 changes: 33 additions & 0 deletions packages/electric-db-collection/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,38 @@
# @tanstack/electric-db-collection

## 0.2.4

### Patch Changes

- Fixed bug where `like()` and `ilike()` operators were not working in on-demand mode. The SQL compiler was incorrectly treating these operators as function calls (`LIKE(column, pattern)`) instead of binary operators (`column LIKE pattern`). Now `like()` and `ilike()` correctly compile to SQL binary operator syntax, enabling search queries with pattern matching in on-demand mode. This fix supports patterns like `like(lower(offers.title), '%search%')` and combining multiple conditions with `or()`. ([#884](https://github.com/TanStack/db/pull/884))

- Fix progressive mode to use fetchSnapshot and atomic swap ([#852](https://github.com/TanStack/db/pull/852))

Progressive mode was broken because `requestSnapshot()` injected snapshots into the stream in causally correct position, which didn't work properly with the `full` mode stream. This release fixes progressive mode by:

**Core Changes:**
- Use `fetchSnapshot()` during initial sync to fetch and apply snapshots immediately in sync transactions
- Buffer all stream messages during initial sync (renamed flag to `isBufferingInitialSync`)
- Perform atomic swap on first `up-to-date`: truncate snapshot data → apply buffered messages → mark ready
- Track txids/snapshots only after atomic swap (enables correct optimistic transaction confirmation)

**Test Infrastructure:**
- Added `ELECTRIC_TEST_HOOKS` symbol for test control (hidden from public API)
- Added `progressiveTestControl.releaseInitialSync()` to E2E test config for explicit transition control
- Created comprehensive progressive mode E2E test suite (8 tests):
- Explicit snapshot phase and atomic swap validation
- Txid tracking behavior (Electric-only)
- Multiple concurrent snapshots with deduplication
- Incremental updates after swap
- Predicate handling and resilience tests

**Bug Fixes:**
- Fixed type errors in test files
- All 166 unit tests + 95 E2E tests passing

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.2.3

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/electric-db-collection/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/electric-db-collection",
"description": "ElectricSQL collection for TanStack DB",
"version": "0.2.3",
"version": "0.2.4",
"dependencies": {
"@electric-sql/client": "^1.1.5",
"@standard-schema/spec": "^1.0.0",
Expand Down
7 changes: 7 additions & 0 deletions packages/powersync-db-collection/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/powersync-db-collection

## 0.1.8

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.7

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/powersync-db-collection/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/powersync-db-collection",
"description": "PowerSync collection for TanStack DB",
"version": "0.1.7",
"version": "0.1.8",
"dependencies": {
"@standard-schema/spec": "^1.0.0",
"@tanstack/db": "workspace:*",
Expand Down
11 changes: 11 additions & 0 deletions packages/query-db-collection/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,16 @@
# @tanstack/query-db-collection

## 1.0.3

### Patch Changes

- Improved the type of the queryFn's ctx.meta property of the Query Collection to include the loadSubsetOptions ([#857](https://github.com/TanStack/db/pull/857))

- Fixed bug where optimistic state leaked into syncedData when using writeInsert inside onInsert handlers. Previously, when syncing server-generated fields (like IDs or timestamps) using writeInsert within an onInsert handler, the QueryClient cache was updated with combined visible state (including optimistic changes), which triggered the query observer to write optimistic values back to syncedData. Now the cache is correctly updated with only server-confirmed state, ensuring syncedData maintains separation from optimistic state. ([#879](https://github.com/TanStack/db/pull/879))

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 1.0.2

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/query-db-collection/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/query-db-collection",
"description": "TanStack Query collection for TanStack DB",
"version": "1.0.2",
"version": "1.0.3",
"dependencies": {
"@standard-schema/spec": "^1.0.0"
},
Expand Down
7 changes: 7 additions & 0 deletions packages/react-db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/react-db

## 0.1.48

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.47

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/react-db/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/react-db",
"description": "React integration for @tanstack/db",
"version": "0.1.47",
"version": "0.1.48",
"author": "Kyle Mathews",
"license": "MIT",
"repository": {
Expand Down
7 changes: 7 additions & 0 deletions packages/rxdb-db-collection/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/rxdb-db-collection

## 0.1.36

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.35

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/rxdb-db-collection/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/rxdb-db-collection",
"description": "RxDB collection for TanStack DB",
"version": "0.1.35",
"version": "0.1.36",
"dependencies": {
"rxdb": "16.20.0",
"@standard-schema/spec": "^1.0.0",
Expand Down
7 changes: 7 additions & 0 deletions packages/solid-db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/react-db

## 0.1.47

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.46

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/solid-db/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/solid-db",
"description": "Solid integration for @tanstack/db",
"version": "0.1.46",
"version": "0.1.47",
"author": "Kyle Mathews",
"license": "MIT",
"repository": {
Expand Down
7 changes: 7 additions & 0 deletions packages/svelte-db/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
# @tanstack/svelte-db

## 0.1.47

### Patch Changes

- Updated dependencies [[`acb3e4f`](https://github.com/TanStack/db/commit/acb3e4f1441e6872ca577e74d92ae2d77deb5938), [`464805d`](https://github.com/TanStack/db/commit/464805d96bad6d0fd741e48fbfc98e90dc58bebe), [`2c2e4db`](https://github.com/TanStack/db/commit/2c2e4dbd781d278347d73373f66d3c51c6388116), [`15c772f`](https://github.com/TanStack/db/commit/15c772f5e42e49000a2d775fd8e4cfda3418243f)]:
- @tanstack/db@0.5.4

## 0.1.46

### Patch Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/svelte-db/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@tanstack/svelte-db",
"description": "Svelte integration for @tanstack/db",
"version": "0.1.46",
"version": "0.1.47",
"dependencies": {
"@tanstack/db": "workspace:*"
},
Expand Down
Loading