You can use EmailJS as a tool to send emails from react/javascript to your acutal email..
all you have to do is to sign up here: emailjs.com
and link your account with your email
now create a new template in EmailJS that matches your contact inputs.. (this is how you are going to receive data)
then use this command to install emailjs with npm:
npm install @emailjs/browser@3.6.2
after that you can add this to your contact component as a handler function for the form:
import emailjs from "@emailjs/browser";
function sendEmail(e) {
e.preventDefault();
emailjs.sendForm(
"your service id --> from your Emailjs profile",
"your template id --> from your Emailjs profile",
e.target,
"Your personal id from Emailjs profile"
);
}