Adding Cloudflare Worker for Email Support #852
-
I'm trying to add a CF Worker to my Contact page. I want to allow visitors to send me messages with this service: https://blog.cloudflare.com/sending-email-from-workers-with-mailchannels/. In the article, they make it look straightforward: "The only thing you need to do is copy and paste the following code snippet in your /functions/_middleware.ts file." It didn't work on my first attempt. My question is on Doks, would I create and put it in that file? Or should I put that code somewhere else? Thanks for the help and advice! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
I did not npm install @cloudflare/pages-plugin-mailchannels first. |
Beta Was this translation helpful? Give feedback.
I did not npm install @cloudflare/pages-plugin-mailchannels first.