Just use MJML ( https://github.com/mjmlio/mjml ) or mrml ( https://github.com/jdrouet/mrml ). It solves the real problems with building emails without introducing useless abstractions like JSX.
And libraries like mjml-react make it really easy.
21–30 of 60 posts
Just use MJML ( https://github.com/mjmlio/mjml ) or mrml ( https://github.com/jdrouet/mrml ). It solves the real problems with building emails without introducing useless abstractions like JSX.
And libraries like mjml-react make it really easy.
I can see that a few other people already brought up MJML so I hope I can have some value added but basically MJML is fanatical about making sure all their changes are supported on a very wide range of email clients. They have hundreds of contributors and 10k+ starts on Github all fixing bugs and compatibility. The project has 2000+ commits. Any new framework that comes out is going to have a lot of catching up to do.
When I use MJML I feel very confident my email will work on many different email clients. And even be responsive.
[1] https://mjml.io/
Just use MJML ( https://github.com/mjmlio/mjml ) or mrml ( https://github.com/jdrouet/mrml ). It solves the real problems with building emails without introducing useless abstractions like JSX.
Agreed that MJML is great, but I wouldn't call JSX a useless abstraction. Using JSX as a templating language for MJML has real benefits, like being able to use javascript directly in templates instead of having to remember handlebars/mustache/nunjucks/etc templating syntax. And libraries like mjml-react make it really easy. https://github.com/wix-incubator/mjml-react/
Check out https://mailing.run . Similar project that can be embedded or run as a standalone API. Also uses MJML which is indispensable for cross-client compatibility. Another tip, I highly recommend a CSS minifier which inlines styles to fix a variety of CSS priority issues.
I am surprised people haven't brought up Maizzle yet: https://maizzle.com/
It's decent.
> Which of these two codes can you understand faster? To me, the first one, but I’m not convinced JSX is a good idea anywhere and I’ve been writing HTML for 30 years.
But our Emails had to replicate other teams designs 1:1 pixel perfect. So we mostly used the same code blocks.
I needed some sort of framework that would organize those code blocks and jsx was perfect. I generated twig templates out of the JSX and used php to send the emails.