Cldr.Message.canonical_message

You're seeing just the function canonical_message, go back to Cldr.Message module for more information.
Link to this function

canonical_message(message, options \\ [])

View Source

Formats a message into a canonical form.

This allows for messages to be compared directly, or using Cldr.Message.jaro_distance/3.

Arguments

  • message is a CLDR message in binary form

  • options is a keyword list of options. The default is []

Options

  • :trim determines if the message is trimmed of whitespace before formatting. The default is true.

  • :pretty determines if the message if formatted with indentation to aid readability. The default is false.

Returns

  • {ok, canonical_message} where canonical_message is a binary or

  • {:error, {exception, reason}}

Examples