Skip to content

Conversation

@elohmeier
Copy link
Contributor

@elohmeier elohmeier commented Dec 11, 2025

Adds SingleResult support to useLiveQuery, matching the React implementation. When using .findOne(), data is typed as T | undefined instead of Array<T>.

Basically ports #440 to svelte-db.

@changeset-bot
Copy link

changeset-bot bot commented Dec 11, 2025

🦋 Changeset detected

Latest commit: 88ecc6c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@tanstack/svelte-db Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new
Copy link

pkg-pr-new bot commented Jan 6, 2026

More templates

@tanstack/angular-db

npm i https://pkg.pr.new/@tanstack/angular-db@1001

@tanstack/db

npm i https://pkg.pr.new/@tanstack/db@1001

@tanstack/db-ivm

npm i https://pkg.pr.new/@tanstack/db-ivm@1001

@tanstack/electric-db-collection

npm i https://pkg.pr.new/@tanstack/electric-db-collection@1001

@tanstack/offline-transactions

npm i https://pkg.pr.new/@tanstack/offline-transactions@1001

@tanstack/powersync-db-collection

npm i https://pkg.pr.new/@tanstack/powersync-db-collection@1001

@tanstack/query-db-collection

npm i https://pkg.pr.new/@tanstack/query-db-collection@1001

@tanstack/react-db

npm i https://pkg.pr.new/@tanstack/react-db@1001

@tanstack/rxdb-db-collection

npm i https://pkg.pr.new/@tanstack/rxdb-db-collection@1001

@tanstack/solid-db

npm i https://pkg.pr.new/@tanstack/solid-db@1001

@tanstack/svelte-db

npm i https://pkg.pr.new/@tanstack/svelte-db@1001

@tanstack/trailbase-db-collection

npm i https://pkg.pr.new/@tanstack/trailbase-db-collection@1001

@tanstack/vue-db

npm i https://pkg.pr.new/@tanstack/vue-db@1001

commit: 88ecc6c

Copy link
Collaborator

@samwillis samwillis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @elohmeier

@samwillis samwillis merged commit 1e64973 into TanStack:main Jan 6, 2026
7 checks passed
@github-actions github-actions bot mentioned this pull request Jan 6, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Jan 7, 2026

🎉 This PR has been released!

Thank you for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants