mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-12-22 21:51:39 +03:00
34703a3b7d
https://github.com/toeverything/AFFiNE/blob/eyhn/feat/new-sync/packages/common/infra/src/workspace/engine/doc/README.md
34 lines
1.0 KiB
TypeScript
34 lines
1.0 KiB
TypeScript
export * from './app-config-storage';
|
|
export * from './atom';
|
|
export * from './blocksuite';
|
|
export * from './command';
|
|
export * from './di';
|
|
export * from './initialization';
|
|
export * from './lifecycle';
|
|
export * from './livedata';
|
|
export * from './page';
|
|
export * from './storage';
|
|
export * from './utils';
|
|
export * from './workspace';
|
|
|
|
import type { ServiceCollection } from './di';
|
|
import { CleanupService } from './lifecycle';
|
|
import { configurePageServices } from './page';
|
|
import { GlobalCache, GlobalState, MemoryMemento } from './storage';
|
|
import {
|
|
configureTestingWorkspaceServices,
|
|
configureWorkspaceServices,
|
|
} from './workspace';
|
|
|
|
export function configureInfraServices(services: ServiceCollection) {
|
|
services.add(CleanupService);
|
|
configureWorkspaceServices(services);
|
|
configurePageServices(services);
|
|
}
|
|
|
|
export function configureTestingInfraServices(services: ServiceCollection) {
|
|
configureTestingWorkspaceServices(services);
|
|
services.override(GlobalCache, MemoryMemento);
|
|
services.override(GlobalState, MemoryMemento);
|
|
}
|