0.1.0 • Published 6 months ago

@pinia/colada-plugin-retry v0.1.0

Weekly downloads
-
License
MIT
Repository
github
Last release
6 months ago

Retry failed queries or mutations with your Pinia Colada.

Installation

npm install @pinia/colada-plugin-retry

Usage

import { PiniaColadaRetry } from '@pinia/colada-plugin-retry'

// Pass the plugin to Pinia Colada options
app.use(PiniaColada, {
  // ...
  plugins: [
    PiniaColadaRetry({
      // Pinia Colada Retry options
    }),
  ],
})

You can customize the retry behavior individually for each query/mutation with the retry option:

useQuery({
  key: ['todos'],
  query: getTodos,
  retry: {
    // Number of retries, can also be a function
    retry: 3,
    // Delay between retries, can also be a function
    delay: 1000,
  },
})

License

MIT

0.1.0

6 months ago

0.0.3

9 months ago

0.0.2

12 months ago

0.0.5

7 months ago

0.0.4

8 months ago

0.0.6

6 months ago

0.0.1

1 year ago

0.0.0

1 year ago