Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Contact Form <[email protected]> #28

Open
sjcrippa opened this issue Mar 19, 2024 · 2 comments
Open

Contact Form <[email protected]> #28

sjcrippa opened this issue Mar 19, 2024 · 2 comments

Comments

@sjcrippa
Copy link

sjcrippa commented Mar 19, 2024

Hi, I've a question, what should we do with the "from" prop that we hardcode with "Contact Form [email protected]" ?? Shouldn't the senderEmail go there? Because when I put it on it doesn't work. Thx!!!!

@sjcrippa sjcrippa changed the title Contact Form <[email protected]> Contact Form <[email protected]> Mar 19, 2024
@Prajwalg19
Copy link

Prajwalg19 commented Mar 26, 2024

you can put the sender's email to the "from" property of the resend.emails.send() function by doing so

try { 
        await resend.emails.send({
            from: `${senderEmail} <[email protected]>`,
            to: "[email protected]", // can only send to the email that has been registered in the resend website.
            subject: "Contacting from the portfolio",
            reply_to: senderEmail as string,
            react: React.createElement(Email_styled, {
                message: message as string,
                senderEmail: senderEmail as string,
            }),
        });
    } catch (e: unknown) {
        return giveMeTheError(e);
    }

@sjcrippa
Copy link
Author

sjcrippa commented Apr 4, 2024

Okay thanks, I tested it and fails but I think that it's because I need a domain (it's seems that vercel's domains also doesn't work) to verify into Resend server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants