Introduces comprehensive data management system for calendar V2 - Adds IndexedDB storage with pluggable entity services - Implements EventBus for decoupled event communication - Creates data seeding mechanism for initial application setup - Establishes sync and repository abstractions for flexible data handling
18 lines
505 B
TypeScript
18 lines
505 B
TypeScript
/**
|
|
* IStore - Interface for IndexedDB ObjectStore definitions
|
|
*
|
|
* Each entity store implements this interface to define its schema.
|
|
* Enables Open/Closed Principle: IndexedDBContext works with any IStore.
|
|
*/
|
|
export interface IStore {
|
|
/**
|
|
* The name of the ObjectStore in IndexedDB
|
|
*/
|
|
readonly storeName: string;
|
|
|
|
/**
|
|
* Create the ObjectStore with its schema (indexes, keyPath, etc.)
|
|
* Called during database upgrade (onupgradeneeded event)
|
|
*/
|
|
create(db: IDBDatabase): void;
|
|
}
|