i have this form say
<form onSubmit={this.formSubmit} id="userForm" name="myForm" noValidate>
im trying to call another function inside my formsubmit() function but it says the function is not defined . what could the reason be
formSubmit=(e)=>{
e.preventDefault();
validateForm();
}
validateForm=()=>{
console.log("test")
}
>Solution :
You need to call this.validateForm(). validateForm is bound to the component instance.