> For the complete documentation index, see [llms.txt](https://brigad.gitbook.io/redux-rest-easy/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://brigad.gitbook.io/redux-rest-easy/docs/api/reset.md).

# reset

Resets the whole store to its original state

## Arguments

None

## Returns

Nothing

## Example

This example demonstrates how to use `reset` to reset the store when the user logs out.

```javascript
import React from 'react';
import { reset, connect } from '@brigad/redux-rest-easy';

const LogoutButton = ({ logout }) => (
  <button onClick={logout}>{'Logout'}</button>
);

const mapDispatchToProps = dispatch => ({
  logout: () => dispatch(reset()),
});

export default connect(null, mapDispatchToProps)(LogoutButton);
```

## Tips

* Just like any action, you have to dispatch `reset` for it to work
