WIP: Experimental implementation for compiling email templates (usage from foundation for emails) #338
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First of all, I would like to say that I am aware that this adjustments probably will not be merged and we have to use our fork, but I want to open this PR anyway, in order to possibly trigger a discussion. Maybe that's also interesting for others.
This PR implements zurb/panini, zurb/inky and an inline-css plugin to basically use foundation for emails. The gulp tasks are adopted from zurb/foundation-emails-template.
With this toolset you're having the possibility to create your own email templates without the pain of writing html tables, because inky will provide syntactic sugar and will take convert your code to tables etc. See here: https://foundation.zurb.com/emails/docs/inky.html
I integrated the tasks into frontools to use the existing features like inheritance and the watcher. There are 2 new helper and 4 new tasks. The helper are
inky
andinliner
and the tasks areinky
,inliner
,email
(building emails for production with inliner),dev:email
(tasks for developing email templates with watcher and browser sync for preview).I've recorded a little example which will show how it's working: https://demo-frontools-email-wfttfpigcx.now.sh/
At the end I would like to say once again, that I'm aware that this will very likely not get merged. There are still some points that need to be solved, for example there is a pending patch for panini to get it working with absolute paths, i will do further testing and maybe fix some things and the readme needs to be adjusted do document the new tasks.
I think with the ideas for frontools 2.0 #201, it will be much easier to add something like this as a plugin.
And finally thanks for this great tool 🙏🏻, this makes developing magento 2 themes much more friendly. Without frontools, it's really cumbersome.