The base role of mapDispatchToProps is exactly what you do inline in your example, however, it is more flexible as it can accept not only the dispatcher but the target component's state and own props.
You can use these extra parameters to change behavior based on component state (for example if it is disabled then you may return no bound actions) or props (for example, if there is cleanStorage in own props of the component, pass it along the logout action).
Using mapDispatchToProps makes your code cleaner and better separated. Imagine passing 10+ actions and binding them manually... Consumer components should only accept defined actions, not a generic dispatch and by that, it reduces coupling to the Redux and allows for easier maintenance and testing.
By using some advanced features you can define simpler function bind, where you just bind the dispatch function to the action creators, for example like this:
const bind => actions => dispatch =>
Object.entries(actions)
.map(([key, action]) => [key, (...args) => dispatch(action(...args)])
.reduce((acc, ([key, boundAction]) => ({...acc, [key]: boundAction}), {})
connect(mapStateToProps, bind( { toggleSidebar, logout } ), ...)(Component)
Or just use bindActionCreators(actionCreators, dispatch) to reduce boilerplate:
import { bindActionCreators } from 'redux';
connect(
mapStateToProps,
dispatch => bindActionCreators( { toggleSidebar, logout }, dispatch),
...
)(Component)