bryonbean / mjml
MJML Compiler for PHP
Installs: 688
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 1
Open Issues: 6
pkg:composer/bryonbean/mjml
Requires
Requires (Dev)
- phpunit/phpunit: ^8.5
This package is auto-updated.
Last update: 2025-10-26 02:04:32 UTC
README
Description
A PHP API for MailJet's mjml transpiler.
Installation
$ composer require bryonbean/mjml
Requirements
- The
npmexecutable must be available in PATH. - The node executable must be located at
/usr/local/bin/node
Usage
use Mjml\Factory; use Mjml\Compiler; $mjml = ' <mjml> <mj-body> <mj-section> <mj-raw><p>Hello world</p></mj-raw> </mj-section> </mj-body> </mjml> '; $factory = new Factory(); $compiler = new Compiler($factory); $compiler->compile($mjml, '/path/to/my/template');
Contributing
Pull requests are welcome. For major changes please open an issue first to discuss what you would like to change.