Editor.js is a beautiful block based wysiwyg editor. It also offers image uploads.
Configuring Mailcoach
Set the mailcoach.campaign.editor
and mailcoach.automationMail.editor
config values to \Spatie\MailcoachEditor\Editor::class
Configuring the Editor
You can publish the configuration file using
php artisan vendor:publish --provider="Spatie\MailcoachEditor\MailcoachEditorServiceProvider" --tag="mailcoach-editor-config"
The Editor also supports image uploads, you can configure the disk_name
in the mailcoach-editor.php
config file.
The package does not automatically delete uploads. If you upload files and replace them, the original files will still be stored on disk.
To remove unwanted uploads, delete the relevant Spatie\MediaLibrary\MediaCollections\Models\Media
models via code.
Spatie\MediaLibrary\MediaCollections\Models\Media::find($mediaId)->delete();
This way the files will also be deleted from the filesystem.
Switching to and from the Editor
This Editor stores content in a structured way. When switching from or to the Editor, content in existing templates and draft campaigns might get lost.