attributes: Modify defaults

Description Usage Arguments Functions See Also Examples

Description

This tag allows you to modify default attributes on a ml_tag and add mj_class to them.

Usage

1
2
3
4
5

Arguments

...

Unnamed items that comprise this list of MJML tags.

Functions

See Also

https://mjml.io/documentation/#mjml-attributes

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
mj_ml(
  mj_head(
    mj_attributes(
      mj_text(padding = 0),
      mj_class(name = "blue", color = "blue"),
      mj_class(name = "big", `font-size` = "20px"),
      mj_all(`font-family` = "Arial")
    )
  ),
  mj_body(
    mj_container(
      mj_section(
        mj_column(
          mj_text(
            `mj-class` = "blue big",
            "Blue text in Arial and 20px"
          )
        )
      )
    )
  )
)

JohnCoene/mjml documentation built on June 21, 2020, 11:42 a.m.