Yes, you can do this. You can also even process the state and return the object.
function mapStateToProps(state){ let completed = someFunction (state); return { completed : completed, }}
This would be useful if you want to shift the logic related to state from render function to outside of it.