Table of Contents

Interface IEmailTemplateRenderer

Namespace
MailForge.Templates
Assembly
MailForge.dll

Renders Razor templates registered on the MailForge builder. Templates use Razor syntax and can reference the model through @Model.

public interface IEmailTemplateRenderer

Methods

Render<TModel>(string, TModel)

Renders a Razor template against a model.

string Render<TModel>(string template, TModel model)

Parameters

template string

The Razor template content.

model TModel

The model instance.

Returns

string

The rendered output.

Type Parameters

TModel

The model type.