[PR #7255] [MERGED] fix(client): add refetch to useSession types for all clients #24079

Closed
opened 2026-04-15 22:09:55 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/7255
Author: @Paola3stefania
Created: 1/11/2026
Status: Merged
Merged: 1/12/2026
Merged by: @himself65

Base: canaryHead: fix/add-refetch-to-all-clients


📝 Commits (3)

  • f2226df feat: add refecth to all clients
  • e6b058d Merge branch 'canary' into fix/add-refetch-to-all-clients
  • e734be2 make lint happy

📊 Changes

5 files changed (+171 additions, -0 deletions)

View changed files

📝 packages/better-auth/src/client/client.test.ts (+154 -0)
📝 packages/better-auth/src/client/solid/index.ts (+4 -0)
📝 packages/better-auth/src/client/svelte/index.ts (+4 -0)
📝 packages/better-auth/src/client/vanilla.ts (+5 -0)
📝 packages/better-auth/src/client/vue/index.ts (+4 -0)

📄 Description

THis closes https://github.com/better-auth/better-auth/issues/3718

Used https://github.com/better-auth/better-auth/pull/4367 as inspo


Summary by cubic

Added refetch(queryParams) and isRefetching to useSession types for Solid, Svelte, Vue, and Vanilla clients. This fixes missing typings and enables typed session refetch using SessionQueryParams.

  • Bug Fixes
    • Updated useSession return types to include refetch(queryParams?: { query?: SessionQueryParams }) and isRefetching across all clients.
    • Added type tests for Solid, Svelte, Vue, and Vanilla to ensure correct refetch typings.

Written for commit e734be2054. Summary will update on new commits.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/7255 **Author:** [@Paola3stefania](https://github.com/Paola3stefania) **Created:** 1/11/2026 **Status:** ✅ Merged **Merged:** 1/12/2026 **Merged by:** [@himself65](https://github.com/himself65) **Base:** `canary` ← **Head:** `fix/add-refetch-to-all-clients` --- ### 📝 Commits (3) - [`f2226df`](https://github.com/better-auth/better-auth/commit/f2226df19c152ecb94d2cc5dfdcce2b3d77be5ab) feat: add refecth to all clients - [`e6b058d`](https://github.com/better-auth/better-auth/commit/e6b058d97f430608b1c4e415d39737f11bebc1ca) Merge branch 'canary' into fix/add-refetch-to-all-clients - [`e734be2`](https://github.com/better-auth/better-auth/commit/e734be20542d7bac92cc7f3229e4541bce5a90db) make lint happy ### 📊 Changes **5 files changed** (+171 additions, -0 deletions) <details> <summary>View changed files</summary> 📝 `packages/better-auth/src/client/client.test.ts` (+154 -0) 📝 `packages/better-auth/src/client/solid/index.ts` (+4 -0) 📝 `packages/better-auth/src/client/svelte/index.ts` (+4 -0) 📝 `packages/better-auth/src/client/vanilla.ts` (+5 -0) 📝 `packages/better-auth/src/client/vue/index.ts` (+4 -0) </details> ### 📄 Description THis closes https://github.com/better-auth/better-auth/issues/3718 Used https://github.com/better-auth/better-auth/pull/4367 as inspo <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Added refetch(queryParams) and isRefetching to useSession types for Solid, Svelte, Vue, and Vanilla clients. This fixes missing typings and enables typed session refetch using SessionQueryParams. - **Bug Fixes** - Updated useSession return types to include refetch(queryParams?: { query?: SessionQueryParams }) and isRefetching across all clients. - Added type tests for Solid, Svelte, Vue, and Vanilla to ensure correct refetch typings. <sup>Written for commit e734be20542d7bac92cc7f3229e4541bce5a90db. Summary will update on new commits.</sup> <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 22:09:55 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#24079