Skip to content

Commit

Permalink
Formatter number : changing from object to two strings
Browse files Browse the repository at this point in the history
  • Loading branch information
Hartorn committed Nov 8, 2017
1 parent 90deb29 commit fd84fdf
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/definition/formatter/number.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,12 @@ function format(number, format) {
}

/**
* Initialize numeral locale and default format
* Initialize numeral locale and default format.
*
* @param {any} { format = DEFAULT_FORMAT, locale = 'fr' }
* @param {string} [format='0,0'] format to use
* @param {string} [locale='fr'] locale to use
*/
function init({ format = DEFAULT_FORMAT, locale = 'fr' }) {
function init(format = DEFAULT_FORMAT, locale = 'fr') {
numeral.locale(locale);
numeral.defaultFormat(format);
}
Expand Down

0 comments on commit fd84fdf

Please sign in to comment.