Skip to content

tauri-plugin-store: typescript mismatch for attribute autoSave #1865

Closed

Description

@binarybaron

The autoSave has the wrong type in the typescript definitions.

export type StoreOptions = {
    /**
     * Auto save on modification with debounce duration in milliseconds
     */
    autoSave?: boolean;
};

autoSave should be of type number, not boolean.

Activity

  1. linked a pull request that will close this issuerefactor(store)!: more reworks #1860on Oct 3, 2024
  2. Legend-Master commented on Oct 3, 2024

    @Legend-Master
    Contributor

    The intention was to use number | undefined here since auto save was off by default, but this commit made a mistake so...

    Anyways, in the new refactor #1860 I'm currently thinking we enable auto save by default and the option will be false to disable auto save, true | undefined for the default auto save duration, number for a custom auto save duration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions