User:YvanZo/Draft/MusicBrainz Email Renderer: Difference between revisions

From MusicBrainz Wiki
Jump to navigationJump to search
(Initial draft of an idea proposed during the summit 23)
 
(→‎MJML email renderer: Fix formatting)
Line 10: Line 10:
So far these emails are generated in text only format using [http://template-toolkit.org/ Template Toolkit] which has had its day.
So far these emails are generated in text only format using [http://template-toolkit.org/ Template Toolkit] which has had its day.


A modern replacement can be [MJML https://mjml.io/] through either the React.js wrapper [https://github.com/Faire/mjml-react mjml-react] or the Rust reimplementation [https://github.com/jdrouet/mrml MRML].
A modern replacement can be [https://mjml.io/ MJML] through either the React.js wrapper [https://github.com/Faire/mjml-react mjml-react] or the Rust reimplementation [https://github.com/jdrouet/mrml MRML].
The first option would allow to reuse some components from the website frontend which has been mostly converted to React ([[jira:MBS-8609]]),
The first option would allow to reuse some components from the website frontend which has been mostly converted to React ([[jira:MBS-8609]]),
while the second option would be blazing fast (170× faster than the original Node.js implementation) but would require much work for components.
while the second option would be blazing fast (170× faster than the original Node.js implementation) but would require much work for components.

Revision as of 16:34, 29 November 2023

MJML email renderer

Proposed mentors: bitmap, reosarevok, yvanzo
Languages/skills: React.js, Rust
Forum for discussion
Estimated Project Length: TBD hours
Difficulty: TBD

MusicBrainz Server can send emails to users in different occasions: email verification, edit notes, subscription edits, autoeditor election… So far these emails are generated in text only format using Template Toolkit which has had its day.

A modern replacement can be MJML through either the React.js wrapper mjml-react or the Rust reimplementation MRML. The first option would allow to reuse some components from the website frontend which has been mostly converted to React (jira:MBS-8609), while the second option would be blazing fast (170× faster than the original Node.js implementation) but would require much work for components.