LanguageList.find

You're seeing just the function find, go back to LanguageList module for more information.

Allows for query of language data by attribute.

Permitted keys: :name , :iso_639_3 , :iso_639_1

Examples

iex> LanguageList.find("Icelandic", :name)
{:ok, %{common: true, iso_639_1: "is", iso_639_3: "isl", name: "Icelandic"}}

iex> LanguageList.find("pt", :iso_639_1)
{:ok, %{common: true, iso_639_1: "pt", iso_639_3: "por", name: "Portuguese"}}

iex> LanguageList.find("por", :iso_639_3)
{:ok, %{common: true, iso_639_1: "pt", iso_639_3: "por", name: "Portuguese"}}

iex> LanguageList.find("non-existent-language", :name)
{:error, "No matches found"}