Using Twig and Views to Create Friendly HTML E-newsletter Code

Stronger integration between Drupal and email marketing systems can benefit many types of organizations looking to streamline processes and lower costs. This session will present a challenge that we believe will be relevant to many organizations and walk attendees step-by-step through a solution that has worked well for us.

THE PROBLEM
A communications person with only rudimentary knowledge of HTML needs to turn a Drupal 8, Bootstrap 4-themed webpage into a Constant Contact e-newsletter. The Views-generated page features a long list of article summaries (the content type) that are grouped by headers with icons. The e-newsletter version needs to have the same styles as the website and look identical to the webpage layout.

THE SOLUTION
Session attendees will see how we implemented a solution using views and twig templates to auto-generate e-newsletter-friendly code to copy and paste into Constant Contact.

Joshua Yospyn
Web Design and Photographer @ John Snow, Inc.
Drupal 8 front-end designer who uses SASS, twig and designs comps in Adobe XD for John Snow, Inc. on a part-time basis. Former photojournalist. Former freelancer for The Washington Post and documentary filmmaker.

https://www.midcamp.org/2020/topic-proposal/using-twig-and-views-create-friendly-html-e-newsletter-code

Drupal is a registered trademark of Dries Buytaert.