To connect Subscribe form to the Mailchimp - you need to do following:
- Create new Signup form -> Embedded form in the Mailchim dashboard
- No need to configure it anyhow. Only thing we need is to create classic Embedded Form
- Then click on Generate Embed Code
- Then grab
"action"
from the<form>
tag. It should look likeaction="https://xxx.xx.list-manage.com/subscribe/post?u=<VALUE_OF_U_VARIABLE>&id=<VALUE_OF_ID_VARIABLE>"
- Copy
.env.sample
file and rename it to be just.env
- Fill in values.
REACT_APP_SUBSCRIBE_FORM_DOMAIN
corresponds toxxx.xx.list-manage.com
REACT_APP_SUBSCRIBE_FORM_U
corresponds toVALUE_OF_U_VARIABLE
REACT_APP_SUBSCRIBE_FORM_ID
corresponds toVALUE_OF_ID_VARIABLE
- For deploying anywhere - you just need to pass expected content of
.env
file as Environment Variables.
That's it! Subscribe form connected, from now on - you can collect mail addresses.