Metadata-Version: 2.1
Name: jinja2-mjml
Version: 0.1.0
Summary: Jinja2 integration with MJML
Home-page: https://github.com/hyzyla/jinja2_mjml
License: MIT
Keywords: jinja2,mjml,email
Author: Yevhenii Hyzyla
Author-email: hyzyla@gmail.com
Requires-Python: >=3.7,<4.0
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Requires-Dist: Jinja2 (>=3.1.2,<4.0.0)
Requires-Dist: mjml-python (>=0.1.0,<0.2.0)
Project-URL: Repository, https://github.com/hyzyla/jinja2_mjml
Description-Content-Type: text/markdown

# Jinja2 MJML

Micro-package that integrates [MJML](https://mjml.io/) 
with [Jinja2](https://jinja.palletsprojects.com/en/2.11.x/).

Under the hood it uses [mjml_python](https://pypi.org/project/mjml-python/) 
package, that is a wrapper around [rust port](https://github.com/jolimail/mrml-core)
of MJML.

## Example

```python
from jinja2_mjml import Environment

# MJMLEnvironment it's thin wrapper around jinja2.Environment,
# so you can use all the features of Jinja2 package.
environment = Environment()
template = environment.from_string('''
    <mjml>
      <mj-body>
        <mj-section>
          <mj-column>
            <mj-text>Hello {{ name }}!</mj-text>
          </mj-column>
        </mj-section>
      </mj-body>
    </mjml>
''')

# Render MJML template to HTML
print(template.render(name='MJML'))
```
