Skip to content

2.1.0-RC10: languageName function

Compare
Choose a tag to compare
@andimiller andimiller released this 10 Mar 14:42
· 18 commits to master since this release
5cf1d1f

This release adds a new function called languageName to core.

It uses the JVM's java.util.Locale database to look up the name of an ISO 639 language code.

It can be called on a string to convert it to a name if one's available, in the JVM's default locale:

language_name = language_code.languageName()

It can also be called with an argument to specify which locale to localize into:

language_name = language_code.languageName("en")