mirror of
https://github.com/better-auth/better-auth.git
synced 2026-05-27 17:36:42 -05:00
docs: add customSessionClient import (#673)
This commit is contained in:
@@ -179,6 +179,7 @@ This will add `roles` and `user.newField` to the session response.
|
||||
**Infer on the Client**
|
||||
|
||||
```ts title="client.ts"
|
||||
import { customSessionClient } from "better-auth/client/plugins";
|
||||
import type { auth } from "@/lib/auth"; // Import the auth instance as a type
|
||||
|
||||
const authClient = createAuthClient({
|
||||
|
||||
@@ -4,7 +4,7 @@ import { customSession } from ".";
|
||||
import { admin } from "../admin";
|
||||
import { createAuthClient } from "../../client";
|
||||
import { customSessionClient } from "./client";
|
||||
import type { BetterAuthOptions, InferUser } from "../../types";
|
||||
import type { BetterAuthOptions } from "../../types";
|
||||
import { adminClient } from "../admin/client";
|
||||
|
||||
describe("Custom Session Plugin Tests", async () => {
|
||||
|
||||
Reference in New Issue
Block a user