Save your email with .mjml extension.

mj_convert(mjml, output = NULL, path = NULL)

mj_validate_mjml(input, path = NULL)

mj_sendmailr(mjml, path = NULL)

Arguments

mjml

MJML email as returned by mj_ml.

path

Path to mjml installation, if NULL attempts to find the path with find_mjml.

input, output

input and output files.

...

Any other option to be passed to writeLines.

Value

Path to output.

Functions

  • mj_convert Convert to .html.

  • mj_validate_mjml Validate .mjml file.

  • mj_sendmailr Convert mjml to sendmailR mimepart.

See also

Examples

email <- mj_ml( mj_body( mj_container( mj_section( mj_column( mj_text("First column") ), mj_column( mj_text("Second column") ) ), mj_section( mj_column( mj_image(paste0("https://media.vanityfair.com/photos/", "54cbf3da998d4de83ba3602a/master/w_960,", "c_limit/image.jpg") ) ) ) ) ) )
# NOT RUN { html <- mj_convert(email) # }