UNPKG

everything-dev

Version:

A consolidated product package for building Module Federation apps with oRPC APIs.

22 lines (20 loc) • 824 B
import { deleteSessionHandle, nearCredentialsPath, readSessionHandle, removePublishedKeyFile, writeSessionHandle } from "./session.mjs"; import { Context, Layer } from "effect"; //#region src/services/auth/session-store.ts /** * The `.bos/session.json` handle as a Context.Service tag (ticket #423): the * auth handlers yield the store instead of importing the session module * directly, keeping the login/logout flows swappable in tests. */ var SessionStore = class SessionStore extends Context.Service()("everything-dev/auth/session-store") { static Live = Layer.succeed(this, SessionStore.of({ read: readSessionHandle, write: writeSessionHandle, delete: deleteSessionHandle, removePublishedKeyFile, nearCredentialsPath })); }; //#endregion export { SessionStore }; //# sourceMappingURL=session-store.mjs.map