# What are the different ways to write .css-1kc89wa{color:purple.500;}`mapDispatchToProps()`?

There are a few ways of binding action creators to `dispatch()` in `mapDispatchToProps()`.

Below are the possible options:

`.css-1kuy7z7{font-size:14px;}const mapDispatchToProps = (dispatch) => ({  action: () => dispatch(action()),});`
`.css-1kuy7z7{font-size:14px;}const mapDispatchToProps = (dispatch) => ({  action: bindActionCreators(action, dispatch),});`
`.css-1kuy7z7{font-size:14px;}const mapDispatchToProps = { action };`

The third option is just a shorthand for the first one.

Author of content
Edit this page

Made by Michael Sakhniuk