UNPKG

@andreaswissel/uiflow

Version:

Adaptive UI density management library with progressive disclosure, element dependencies, A/B testing, and intelligent behavior-based adaptation

50 lines 1.3 kB
export { BaseDataSource } from "./base.js"; export { APIDataSource } from "./api.js"; export { SegmentDataSource } from "./segment.js"; /** * Data source manager for handling multiple sources */ export class DataSourceManager { sources: Map<any, any>; primary: any; /** * Add a data source * @param {string} name - Data source name * @param {BaseDataSource} source - Data source instance * @param {boolean} isPrimary - Whether this is the primary source for reading data */ addSource(name: string, source: BaseDataSource, isPrimary?: boolean): void; /** * Initialize all data sources */ initialize(): Promise<void>; /** * Push data to all sources */ pushData(userId: any, data: any): Promise<void>; /** * Pull data from primary source */ pullData(userId: any): Promise<any>; /** * Track event in all sources */ trackEvent(userId: any, event: any): Promise<void>; /** * Get source by name */ getSource(name: any): any; /** * Get all source names */ getSourceNames(): any[]; /** * Remove a source */ removeSource(name: any): void; /** * Destroy all sources */ destroy(): void; } //# sourceMappingURL=index.d.ts.map