API Documentation
    Preparing search index...

    Class SyncWritableInMemoryStore<ItemType, IDType>

    A writable synchronous store.

    Type Parameters

    • ItemType extends Record<string, any>
    • IDType extends string | number

    Hierarchy (View Summary)

    Implements

    Index

    Properties

    id: string

    ID of the store.

    idProperty: string

    Name of the property used as ID. If not provided, the 'getIdentity' method must be declared.

    Methods

    • Emits an event. All associated event listeners registered for the given event name will be invoked asynchronously.

      Type Parameters

      • Name extends "changed"

      Parameters

      • eventName: Name

        The name of the event.

      • ...value: Params<StoreEvents<IDType>[Name]>

        The event value. Passed to all event listeners. Note: no value can be passed if the event type is void.

      Returns void

    • Delete an item by id.

      Parameters

      • id: IDType

        id of item to delete

      Returns void