laravel-mail-editor
laravel-mail-editor copied to clipboard
Extending other mail templates
I see that I cannot extend my mailable from a default design Would be great to have, so the designs are all consistent and dry
@extends('core.customer.layouts.email')
@section('content')
<
Hi @robov, would you be able to provide some a more clearer example of this suggestion?
We can maybe get someone to work on it during Hacktoberfest or before then.
From what I understand, you are suggesting extending a template that you have made yourself?
Or extending the templates from MailEclipse
I would like my main templates to be based in code (ie, main email design). Then the individual designs through a more dynamic way.
Hi @robov, okay, so basically, you want to have a blade layout that is your base layout and be able to pick that from the maileclipse editor area?
So with a file structure below after creating the mailable
.
├── app/
│ └── Mail/
│ └── MailableClass.php
└── resources/
└── views/
├── core/
│ └── customer/
│ └── layouts/
│ └── email.blade.php <- exists already
└── mail/
└── mailable-class.blade.php
But instead of using the templates provided, the base is a blade file that takes a name that should be extended and saves that as the new mailable-class.blade.php file that looks like this:
@extends('core.customer.layouts.email')
@section('content')
{-- content would go in here and the data that the editor targets--}
@endsection