npm i redux-use-controller
const testController = (dispatch, props) => {
const testUseCase = new TestUseCase();
const payload = testUseCase.test();
dispatch({ type: 'TEST', payload })
}
const MyButton = () => {
const executeTest = useController(testController);
return (
<button onClick={executeTest}>test</button>
);
}