The Cordova Globalization API exposes methods an application can use to help identify the device’s current configuration for language plus the display and conversion of dates, numbers and currency values.

Many mobile applications are initially created with content in English, but in order to address a wider potential audience for the application, the developer may also provide content within the application in different languages. In order to do that, the application must be able to determine what language the user has configured on the device and switch in the appropriate content if available.

Additionally, any application that works with and displays decimal numbers, currencies, percentages, date and time values must be able to format those values as appropriate based upon the locale the user has configured on her device. The Globalization API exposes the methods a developer needs in order to ensure that content is displayed correctly within the application.

For the sample applications for this chapter, I took a different approach from all of the other applications shown in this book. Instead of creating multiple sample applications that demonstrate the operation of each of the API’s methods, I created a quick demo application then a big application that demonstrates everything.