@empathyco/x-components
Version:
Empathy X Components
78 lines (35 loc) • 1.22 kB
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [FetchAndSaveActions](./x-components.fetchandsaveactions.md)
## FetchAndSaveActions interface
Actions returned from the [createFetchAndSaveActions()](./x-components.createfetchandsaveactions.md)<!-- -->.
**Signature:**
```typescript
export interface FetchAndSaveActions<Context extends XActionContext<StatusState, object, StatusMutations, object>, Request>
```
## Properties
<table><thead><tr><th>
Property
</th><th>
Modifiers
</th><th>
Type
</th><th>
Description
</th></tr></thead>
<tbody><tr><td>
[cancelPrevious](./x-components.fetchandsaveactions.cancelprevious.md)
</td><td>
</td><td>
() => void
</td><td>
Action that cancels the previous request call if it stills in progress.
</td></tr>
<tr><td>
[fetchAndSave](./x-components.fetchandsaveactions.fetchandsave.md)
</td><td>
</td><td>
(context: Context, request: Request) => void \| Promise<void>
</td><td>
Action that requests and saves the response.
</td></tr>
</tbody></table>