Swoosh.Email.assign

You're seeing just the function assign, go back to Swoosh.Email module for more information.
Link to this function

assign(email, key, value)

View Source

Specs

assign(t(), atom(), any()) :: t()

Stores a new variable key and value in the email.

This store is meant for variables used in templating. The name should be specified as an atom, the value can be any term.

Examples

iex> new() |> assign(:username, "ironman")
%Swoosh.Email{assigns: %{username: "ironman"}, attachments: [], bcc: [],
 cc: [], from: nil, headers: %{}, html_body: nil, private: %{},
 provider_options: %{}, reply_to: nil, subject: "", text_body: nil, to: []}