Skip to content

API Documentation / @pinia/colada / StreamedQueryRefetchMode

Type Alias: StreamedQueryRefetchMode ​

ts
type StreamedQueryRefetchMode = "reset" | "append" | "replace";

What to do with the existing data when a streamed query is fetched again.

  • 'reset': remove the existing data and go back to the pending status. The data fills again as chunks arrive.
  • 'append': keep the existing data and add new chunks to it.
  • 'replace': keep the existing data until the stream ends, then replace it with the new data in one step.

Released under the MIT License.