Skip to main content

Crate formatjs_intl

Crate formatjs_intl 

Source

Macros§

format_message
Formats an extractable message and returns its default message if infrastructure fails.
formatted_message
Formats extractable text with checked replacements and returns FormattedMessage. Uses the same IDs, locale negotiation, fallback, and error reporting as crate::format_message!. Inline replacement names are checked at compile time.
message_descriptor

Structs§

FormatMessageError
A recoverable message error reported while formatting falls back.
FormattedMessage
Text produced by checked formatting.
Intl
IntlCache
MessageCatalog
MessageDescriptor
MessageDescriptorRef
Borrowed message descriptor for runtime-defined messages.
MessageValues
Checked replacements: formatted messages, domain-owned verbatim arguments, numbers, booleans, and dates.
OwnedMessageDescriptor
Owned descriptor snapshot attached to recovered formatting errors.
Verbatim
An interpolation-only borrow of application-approved content.

Enums§

Error
MessageSource
Identifies the message source that failed during automatic fallback.

Traits§

MessageArgument
An interpolation value accepted by checked formatting. Sealed so unchecked string or rich-text values cannot implement this trait.
VerbatimSource
Application-owned content that may be interpolated without translation.

Functions§

negotiate_locale

Type Aliases§

Messages
PrecompiledMessages
Result