I saw this piece of code in React, like
connect(mapStateToProps, {
test: () => {return { type: 'TEST_ACTION' }}
})(Index);
but I failed to google any explanation. Probably the question is dumb, but I appreciate any help, maybe links to some existing explanations or examples.