Skip to content

Commit 1f9ffad

Browse files
update changesets
1 parent 28b58c8 commit 1f9ffad

File tree

4 files changed

+37
-1
lines changed

4 files changed

+37
-1
lines changed

.changeset/little-bananas-fetch.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@
22
'@powersync/common': minor
33
---
44

5-
Added additional listeners for `closing` and `closed` events in `AbstractPowerSyncDatabase`.
5+
- Added additional listeners for `closing` and `closed` events in `AbstractPowerSyncDatabase`.
6+
- Added `incrementalWatch` API for enhanced watched queries.
7+
- Added `triggerImmediate` option to the `onChange` API. This allows emitting an initial event which can be useful for downstream use cases.

.changeset/nine-pens-ring.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@powersync/vue': minor
3+
---
4+
5+
- Added the ability to limit re-renders by specifying a `comparator` for query results. The `useQuery` hook will only emit `data` changes when the data has changed.
6+
7+
```javascript
8+
useQuery('SELECT * FROM lists WHERE name = ?', ['todo'], {
9+
// This will be used to compare result sets between internal queries
10+
comparator: new ArrayComparator({
11+
compareBy: (item) => JSON.stringify(item)
12+
})
13+
}),
14+
```

.changeset/plenty-rice-protect.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@powersync/react': minor
3+
'@powersync/vue': minor
4+
---
5+
6+
- [Internal] Updated implementation to use shared `WatchedQuery` implementation.

.changeset/swift-guests-explain.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
'@powersync/react': minor
3+
---
4+
5+
- Added the ability to limit re-renders by specifying a `comparator` for query results. The `useQuery` hook will only emit `data` changes when the data has changed.
6+
7+
```javascript
8+
useQuery('SELECT * FROM lists WHERE name = ?', ['todo'], {
9+
// This will be used to compare result sets between internal queries
10+
comparator: new ArrayComparator({
11+
compareBy: (item) => JSON.stringify(item)
12+
})
13+
}),
14+
```

0 commit comments

Comments
 (0)