Y18N v1.0.0 Orisons.Y18N View Source
Module to get translation in a language specified in config.
Link to this section Summary
Functions
Reload translation from yaml
files to ets
Translate string from parameter to language specified in config
Translate string from parameter to language from session stored in Plug.Conn
Translate string from parameter to language specified in config with plural detection
Translate string from parameter to language from session stored in Plug.Conn
, with plural detection
Link to this section Functions
Reload translation from yaml
files to ets
.
Translate string from parameter to language specified in config.
Examples
iex> Orisons.Y18N.y("Hello world")
"Witaj świecie"
Translate string from parameter to language from session stored in Plug.Conn
.
Examples
iex> Orisons.Y18N.y(conn, "Hello world")
"Witaj świecie"
Translate string from parameter to language specified in config with plural detection.
Examples
iex> Orisons.Y18N.y("%d apple", "%d apples", 3)
"3 jabłka"
Translate string from parameter to language from session stored in Plug.Conn
, with plural detection.
Examples
iex> Orisons.Y18N.y(conn, "%d apple", "%d apples", 3)
"3 jabłka"