Template Creation and Management
Notify makes it easy to create reusable email templates that can include both static content and dynamic data. In this guide, we’ll go through the steps to create, edit, and manage templates within the Notify dashboard, as well as how to use placeholders for dynamic content.
1. Creating a New Template
To create a new email template:
- Navigate to the Templates Page: From your dashboard, select Templates from the menu.
- Create New Template: Click on Create Template to start a new template.
- Enter Template Details: Fill in the required fields:
- Template Name: A unique name for the template.
- Template ID: A reference ID used to call the template programmatically.
- Subject Line: Define the subject line for the email.
- Design the Template Body: Use Notify’s editor to add content blocks to your template.
- Elements: Choose from pre-defined elements like
Heading
,Text
,Button
, andImage
. - Text and Styles: Add text content and apply styles using Tailwind CSS classes for consistent styling.
- Elements: Choose from pre-defined elements like
- Dynamic Placeholders: To personalize emails, insert placeholders in the format
{placeholder_name}
, e.g.,{name}
or{company}
. These placeholders will be replaced with actual data when the email is sent.
Example Placeholder: You can include personalized greetings like
Hello, {name}!
in the template to address recipients by their name.
- Save the Template: Once satisfied, click Save Template. The template will now be available for use when sending emails.
2. Editing an Existing Template
To make changes to an existing template:
- Go to the Templates page and select the template you want to edit.
- Update any fields, including the subject line, body content, or placeholders as needed.
- Preview Changes: Use the split-screen preview to see updates in real-time as you make changes to the template.
- Click Save Changes once done.
Note: When editing a live template, ensure that you test changes thoroughly if the template is already in use for production emails.
3. Managing Template Content Blocks
Notify’s editor allows you to organize your template by adding, removing, or rearranging content blocks.
- Add New Blocks: Click Add Block to include new sections like text, headings, buttons, or images.
- Remove Blocks: Hover over a block and click the X to remove it.
- Reorder Blocks: Drag and drop blocks to rearrange the structure of your template.
Each block can have its own text, images, or buttons, and you can apply styling with Tailwind CSS classes to create a cohesive and visually appealing design.
4. Styling Templates with Tailwind CSS
You can style your email templates directly within Notify by applying Tailwind CSS classes to each element.
- Text Styling: Apply classes for text size, color, alignment, and font weight (e.g.,
text-lg font-bold text-center
). - Button Styling: Use Tailwind classes to create custom button styles, such as
bg-blue-500 text-white py-2 px-4 rounded
. - Responsive Layouts: Tailwind’s responsive classes (like
sm:text-lg md:text-xl
) allow you to adjust styling based on device size.
Tip: The split-screen preview lets you see how Tailwind styles affect your template in real-time, making it easier to adjust the design for different screen sizes.
5. Using Dynamic Placeholders
Placeholders let you add personalized content to each email sent using a template. They are formatted as {placeholder_name}
and can be used in any part of your template content.
Example Placeholders
- Recipient’s Name:
{name}
- Company Name:
{company}
- Custom Messages:
{message}
When sending an email with this template, you’ll pass in values for each placeholder, and Notify will replace them with the actual data for each recipient.
Example:
In the template:
Hi, {name}! Welcome to {company}.
At send time:
{ "name": "Alex", "company": "TechCorp" }
Result:
Hi, Alex! Welcome to TechCorp.
6. Previewing Your Template
Before finalizing your template, use the split-screen preview feature to see how it looks with sample data:
- Go to your template and click on Preview.
- Input sample data for placeholders (e.g., name, company) to see the template in action.
- Adjust styling or content as needed based on the preview.
This feature ensures your email looks as intended before you send it out.
7. Testing Templates
Once your template is complete, it’s good practice to test it to confirm that dynamic content and styles render as expected:
- Send a Test Email: Use the Send Test button to send a copy of the email to a specified address.
- Verify Placeholder Replacement: Ensure that placeholders (e.g.,
{name}
,{company}
) are replaced correctly with your test data. - Check Formatting: Confirm that all styling appears as expected across devices and email clients.
8. Deleting a Template
To delete a template:
- Navigate to the Templates page.
- Select the template you wish to delete.
- Click Delete Template and confirm the deletion.
Warning: Deleting a template is irreversible and will remove it from any automated workflows or integrations.