docs: add customSessionClient import (#673)

This commit is contained in:
Lukas Scholten
2024-11-27 13:35:19 +01:00
committed by GitHub
parent 4e3e71c821
commit bc3cdc751a
2 changed files with 2 additions and 1 deletions

View File

@@ -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({

View File

@@ -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 () => {