@empathyco/x-components
Version:
Empathy X Components
18 lines (11 loc) • 759 B
Markdown
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
[Home](./index.md) > [@empathyco/x-components](./x-components.md) > [MutationsTree](./x-components.mutationstree.md)
## MutationsTree type
Type-safe mutations definition type. An object with this type is what it is needed to define [Vuex](https://vuex.vuejs.org/) mutations.
**Signature:**
```typescript
export type MutationsTree<State extends Dictionary, Mutations extends MutationsDictionary<Mutations>> = {
[Key in keyof Mutations]: (state: State, payload: ExtractPayload<Mutations[Key]>) => void;
};
```
**References:** [MutationsDictionary](./x-components.mutationsdictionary.md)<!-- -->, [ExtractPayload](./x-components.extractpayload.md)