Practic BUI (Base UI) - v1.0.0
    Preparing search index...

    Function persistCreateStateIn

    • Declares a persisted value kept in stores of one's own choosing, as @practic/persist does to pick IndexedDB. Stores are looked up on each call, so a handle declared at module scope uses whichever layer is registered by then.

      Type Parameters

      Parameters

      • getStore: (key: string) => PersistKeyStore

        Returns the store of a storage key, the same one each time for the same key.

      • location: PersistLocation<T>

        Where the value lives, and its initial value. Without attr, it stays in memory.

      Returns PersistedState<T>