<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@empathyco/x-components](./x-components.md) &gt; [wireCommit](./x-components.wirecommit_2.md)

## wireCommit() function

Creates a wire that commits a mutation to the store. This wire will commit to the store the payload that it receives in the observable.

**Signature:**

```typescript
export declare function wireCommit<Payload>(mutation: string): Wire<Payload>;
```

## Parameters

|  Parameter | Type | Description |
|  --- | --- | --- |
|  mutation | string | The full mutation path to commit. I.e. <code>x/searchBox/setQuery</code>. |

**Returns:**

[Wire](./x-components.wire.md)<!-- -->&lt;Payload&gt;

[Wire](./x-components.wire.md) A wire that commits the mutation with the payload that it receives in the observable.

