Skip to content

Commit

Permalink
docs: fix suspected typo's and correct phrasing
Browse files Browse the repository at this point in the history
  • Loading branch information
cueedee committed May 22, 2015
1 parent 55dbeff commit 9b2ab2d
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,9 @@ npm install madlib-locale --save

## Setup

To use it you will need to require the module, the module itself will export an singleton object. Before rendering any templates you will first need to call the initialize function to pass the Handlebars reference to extend with the helpers and set the default locale. Calling initialize will return an promise when this is resolved the locale file loaded and you can savely render your templates.
To use it you will need to require the module, the module itself will export a singleton object. Before rendering any templates you will first need to call the initialize function to pass the Handlebars reference to extend with the helpers and set the default locale. Calling initialize will return a promise when this is resolved the locale file loaded and you can savely render your templates.

*optional
Optionally you can pass a thirth parameter to the function which is the localeLocation. This defaults to "/i18n" if you want to put your locale files in a different folder pass this parameter
Optionally you can pass a third parameter which is the `localeLocation`. This defaults to `"/i18n"`. If you want to put your locale files in a different folder, pass this parameter.

```shell
localeManager = require( "madlib-locale" )
Expand All @@ -36,7 +35,7 @@ localeManager.initialize( Handlebars, "en_GB" ).then(

## Change the language

You can change the current language at any time by calling the setLocale function on the localeManager. The function will return an promise, once this is resolved and you re-render you templates they will be in the new language
You can change the current language at any time by calling the `setLocale` function on the localeManager. The function will return a promise, once this is resolved and you re-render you templates they will be in the new language

```shell
localeManager = require( "madlib-locale" )
Expand Down

0 comments on commit 9b2ab2d

Please sign in to comment.