1.2.2 • Published 5 years ago

demo-email-builder v1.2.2

Weekly downloads
2
License
ISC
Repository
github
Last release
5 years ago

Supported components: mj-container mj-section mj-column mj-text mj-image mj-button mj-social mj-divider mj-spacer

Options

OptionDescriptionDefault
categoryLabelCategory for blocks''
importPlaceholderImport placeholder MJML''
modalTitleImportTitle for the import modalImport MJML
modalBtnImportTest for the import buttonImport
modalLabelImportDescription for the import modal''
modalTitleExportTitle for the export modalExport MJML
modalLabelExportDescription for the export modal''
overwriteExportOverwrite default export commandtrue
preMjmlString before the MJML in export code''
postMjmlString after the MJML in export code''
resetBlocksClean all previous blocks if truetrue
resetDevicesClean all previous devices and set a new one for mobiletrue,
resetStyleManagerReset the Style Manager and add new properties for MJMLtrue,

Usage

<link href="path/to/grapes.min.css" rel="stylesheet"/>
<script src="path/to/grapes.min.js"></script>
<script src="path/to/demo-email-builder.min.js"></script>

<div id="gjs">
  <!-- Your MJML body here -->
  <mj-container>
        <mj-section>
          <mj-column>
            <mj-text>My Company</mj-text>
          </mj-column>
        </mj-section>
  <mj-container>
</div>

<script type="text/javascript">
  var editor = grapesjs.init({
      fromElement: 1,
      container : '#gjs',
      plugins: ['demo-email-builder']
  });
</script>