Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is there a way to reuse layouts between dynamic templates in Sendgrid?

We are using Sendgrid and dynamic templates for our service. We have many different communications going over email to our customers quite frequently, so we have over 20 different templates.

I want to reuse the same header, footer and CSS between these templates to avoid typos and make updates easier. Is there any way to use handlebar layouts or partials with Sendgrid Dynamic templates to allow me to do this?

Or is there another good solution or tool that can help? It's not that it is impossibly hard to update this manually, but it is tedious.

Kind regards, David

like image 243
Almund Avatar asked Dec 31 '25 20:12

Almund


1 Answers

I created a helper tool in NodeJS to help generate templates from a layout + content and then uploaded this, overriding existing versions or creating new ones.

Please see: https://github.com/ddikman/sendgrid-dynamic-templates

like image 192
Almund Avatar answered Jan 04 '26 18:01

Almund



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!