feat(core): add public user service (#10695)

This commit is contained in:
EYHN committed 2025-03-07 08:00:27 +00:00
1 parent a08e76c3b5
commit 4677049b5c
10 files changed
+375 -9

No files matched your search

@@ -5,8 +5,9 @@ import type { Signal } from '@preact/signals-core';
import type { AffineUserInfo } from './types';
export interface UserService {
getCurrentUser(): AffineUserInfo;
getUserInfo(id: string): Signal<AffineUserInfo | null>;
getCurrentUser(): AffineUserInfo | null;
userInfo$(id: string): Signal<AffineUserInfo | null>;
revalidateUserInfo(id: string): void;
}
export const UserProvider = createIdentifier<UserService>(
+1 -1
View File
@@ -7,8 +7,8 @@
},
"include": ["./e2e"],
"references": [
{ "path": "../blocks" },
{ "path": "../framework/block-std" },
{ "path": "../blocks" },
{ "path": "../framework/global" },
{ "path": "../framework/inline" },
{ "path": "../integration-test" },