next-pocketbase-auth
Version:
Wrapper for Next.js applications using PocketBase, with support for both client and server components
23 lines (22 loc) • 587 B
TypeScript
import { AuthRecord, BaseAuthStore } from "pocketbase";
import { CookieOptions } from "../types";
type SaveFunction = (serialized: string, cookieOptions: CookieOptions) => void;
type ClearFunction = () => void;
export declare class SyncAuthStore extends BaseAuthStore {
private saveFunc;
private clearFunc;
constructor(config: {
save: SaveFunction;
clear: ClearFunction;
initial?: string;
});
/**
* @inheritdoc
*/
save(token: string, record?: AuthRecord): void;
/**
* @inheritdoc
*/
clear(): void;
}
export {};