mjml-head-attributes
v5.0.1
Published
mjml-head-attributes
Keywords
Readme
mj-attributes
Inside the mj-attributes tag, you can cite other MJML components, like mj-text for example, to override the default settings for that component.
An mj-all tag is like the above, but affects all MJML components.
An mj-class tag creates a named group of MJML attributes you can apply to MJML
components using mj-class="<name>".
<mjml>
<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-attributes>
</mj-head>
<mj-body>
<mj-section>
<mj-column>
<mj-text mj-class="blue big">
Hello World!
</mj-text>
</mj-column>
</mj-section>
</mj-body>
</mjml>