In order to have emails compatible with as many clients as possible, we wrote Twig templates with the MJML framework.
This framework generates complex HTML templates from simple syntax.
We could set-up the MJML service on our local machine, but they gently provide a free API to do the job, the only thing to do is to subscribe.
-
Go to https://mjml.io/api and subscribe.
-
You will receive your API credentials in your mailbox.
Set the following keys according to what mjml.io provided:
MJML_APPLICATION_ID
MJML_PUBLIC_KEY
MJML_PRIVATE_KEY