I have a component like this: 

```
class FormItem extends React.PureComponent {

    constructor(props){
        super();
        props.dispatch(setFormCreated(props.formBuilder, props.formId)); 
    }

   render(){
       ...
   }
}

const mapStateToProps = state => {
    return {
        doValidation: state.formsReducer.validationRequested
    };
};

const mapDispatchToProps = dispatch => ({
    onValidationSucceed: formId =>  dispatch(setFormValidationSucceed(formId)),
    onValidationFailed: formId => dispatch(setFormValidationFailed(formId))
});

export default connect(mapStateToProps, mapDispatchToProps)(FormItem);

```

I want to dispatch an action when the component is created. Line 5:

```
props.dispatch(setFormCreated(props.formBuilder, props.formId)); 

```

But I got:

> 
> TypeError: props.dispatch is not a function
> 
> 
>