Jasig/umobile-app-phonegap — pull request #49 by gsouquet (2014-06-24 10:02:48+00:00)
Title: uMobile internationalization using Polyglot.js

uMobile didn't bring any i18n features. I found a great tool developed by Airbnb named [Polyglot.js](http://airbnb.github.io/polyglot.js/polyglot.html)

So I decided to integrate it with uMobile app. You can translate a text programmaticaly or in an Handlebars template.

__Programmaticaly :__
```javascript
umobile.i18n.t('header.title');
// will output 'uMobile'
```
__In a Handlebars template :__
Simple translation
```javascript
{{t 'header.title'}}
// will output 'uMobile'
```

With extra parameter, view a real [working example](https://github.com/gsouquet/umobile-app-phonegap/compare/i18n#diff-83edb8c22fd632d34e57c077e302bbf3R1)
```javascript
{{t 'hello.name' 'John' 'Doe'}}
// if hello.name = 'Hello my name is %{0} %{1}'
// then it will output 'Hello my name is John Doe
```
Pluralisation
```javascript
{{t 'number.car' 2}}
// if number.car = '%{smart_count} car |||| %{smart_count} cars'
// then it will output '2 cars'
```