Closed md-turismoi closed 3 years ago
Only issue with this is styles don't carry over, not sure if there's a way around that
Also, if, on the off-chance, someone added a comment:
<!-- <mjml> -->
It wouldn't work.
Unlikely, but still a possibility.
That's right.
This feature was designed for scenarios where you have different kinds of emails in your project, you might want to extract some of the shared logic into something you could reuse (email header & footer, replacing dynamically only the body or some sections). In that case, the partial MJML files should not include the shared markups:
baseLayout.mjml
`
`
footer_header.mjml
`
`
@md-turismoi Hi, thanks for this PR and sorry for the wait.
This is useful indeed, but in the mjml-app we have an equivalent feature to allow partials rendering, and we check it like this : if(documentText.trim().startsWith('<mjml'))
I'd prefer it to be the same here, could you please just change this ?
Previous version only allow to preview complete and well-formed MJML files (.... ).
This version allows also to preview partial MJML files (... ) to be able to create dynamic layouts splitting shared headers/footers in different files and include them in run-time.
`
`