useValueOptions: {
    commit?: boolean;
    commitDebounce?: number;
    handleValidationError?: ((e: Error | undefined) => unknown);
    validate?: boolean;
}

Extra options for useValue hooks, mostly related to commits and validation

Type declaration

  • Optional commit?: boolean

    Sends a Commit to the server when the value is changed. Disabled by default. If this is false, you will need to manually call Resource.save() to save changes

  • Optional commitDebounce?: number

    Amount of milliseconds to wait (debounce) before applying Commit. Defaults to 100.

  • Optional handleValidationError?: ((e: Error | undefined) => unknown)
      • (e: Error | undefined): unknown
      • A callback function that will be called when the validation fails. For example, pass a setError function. If you want to remove the Error, return undefined.

        Parameters

        • e: Error | undefined

        Returns unknown

  • Optional validate?: boolean

    Performs datatype validation. Enabled by default, but this could cause some slowdown when the first validation is done as the Property needs to be present in the store, and might have to be fetched

Generated using TypeDoc