Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

@bokeh/numbro

foretagsplatsen30.9k1.6.2

Format and manipulate numbers.

numeral, numbro, number, format, time, money, percentage

readme

numbro

Join the chat at https://gitter.im/foretagsplatsen/numbro

A javascript library for formatting and manipulating numbers.

Website and documentation

Travis Build Status

Master Build Status

Develop Build Status

NPM

NPM

Contributing

Please submit all pull requests to the develop branch.

  1. Fork the library

  2. Install grunt

  3. Run npm install to install dependencies

  4. Add your tests to the files in /tests

  5. To test your tests, run grunt test

  6. When all your tests are passing, submit a pull request to the develop branch.

Languages

Languages names follows the Microsoft culture name convention as found here. If Microsoft does not have a code for the country/locale combination, use the format lang-locale where the language code is a 2 letter abbreviation from the list of ISO 639-1 language codes and the localecode is from the list of ISO 3166-1 country codes

Language translations will not be merged without unit tests.

See the english unit tests for an example.

Changelog

See CHANGELOG.md.

Acknowledgements

numbro is forked from Adam Draper's project Numeral.js, which was in turn inspired by and heavily borrowed from Moment.js.

License

Copyright © 2014 Adam Draper

Copyright © 2015 Företagsplatsen AB


Distributed under the MIT license. If you want to know more, see the LICENSE file.

The original license file for Numeral.js can be found in LICENSE-Numeraljs

changelog

1.6.2

  • Fix deprecated use of language and introduce cultureCode. Thanks @BenjaminVanRyseghem

1.6.1

  • Fix languages to use proper intPrecision. Thanks @BenjaminVanRyseghem
  • Fix intPrecision when value is 0. Thanks @BenjaminVanRyseghem

1.6.0

  • Introduce new API functions:

    • setCulture
    • culture
    • cultureData
    • cultures
  • Deprecate API functions:

    • setLanguage
    • language
    • languageData
    • languages

Those deprecated functions will be removed in version 2.0.0

1.5.2

  • Fixed scoping issue. Thanks @tuimz
  • 68 Format decimal numbers. Thanks @BenjaminVanRyseghem

  • 70 v1.5.0 error with browserify. Thanks @BenjaminVanRyseghem

  • 71 Incorrectly reporting hasModule = true. Thanks @BenjaminVanRyseghem

  • 72 the currency symbol is $ which is a currency symbol already by itself (the dollar..). Thanks @BenjaminVanRyseghem

  • 76 ability to "pad" a number in formatting. Thanks @BenjaminVanRyseghem

  • 79 browserify attempts to load all language files. Thanks @BenjaminVanRyseghem

  • 106 Exception on large number formatting. Thanks @andrewla

1.5.1

  • 78 Why is 0 formatted as +0?. Thanks to @clayzermk1

  • 80 currency format "+$..." produces output "$+...". Thanks to @clayzermk1

  • Fixes German separator. Thanks to @gka

1.5.0

  • Adds support for Hebrew (he-LI). Thanks to @eli-zehavi

1.4.0

  • 62 using languages in node. Thanks @alexkwolfe

1.3.3

  • 64 multiply loses accuracy on minification. Thanks @rafde

1.3.2

  • Fix issue with the release process

1.3.1

  • Fix context issue when in strict mode. Thanks @avetisk

1.3.0

  • 53 Max significant numbers formating. Thanks @BenjaminVanRyseghem

  • 57 Broken reference to this in languages. Thanks @BenjaminVanRyseghem

1.2.2

  • Remove old minified files

1.2.1

  • Forgot to build when published

1.2.0

  • 27 Binary and decimal bytes. Thanks @clayzermk1 and @Graham42

  • 26 Jshint improvemnents. Thanks @baer and @Graham42

  • Fixes french ordinal. Thanks @BenjaminVanRyseghem
  • 32 Use svg instead of png to get better image quality. Thanks @PeterDaveHello

  • 33 Correct culture code for Español. Thanks @maheshsenni

  • 34 Clean up locales info. Thanks @Graham42

  • 36 Improve dist/ layout. Thanks @Graham42

  • 35 Correct Polish currency symbol. Thanks @Graham42

  • Fixes Swedish tests. Thanks @BenjaminVanRyseghem
  • Fixes inconsistent white spaces. Thanks @BenjaminVanRyseghem
  • 44 Tests for culture code format. Thanks @maheshsenni

  • 50 added en-ZA language. Thanks @stewart42

1.1.1

  • Fixes minified version number. Thanks @BenjaminVanRyseghem
  • Removes old minified files. Thanks @Graham42

1.1.0

  • Adds languages to expose all registered languages. Thanks @NicolasPetton
  • Adds support for filipino. Thanks @Graham42 and @mjmaix
  • Adds support for farsi. Thanks @Graham42 and @neo13

1.0.5

  • Improves release process. Thanks @Graham42
  • Updates the README file. Thanks @Graham42
  • Fixes Danish currency symbol. Thanks @Graham42 and @philostler
  • Fixes npm/bower dependencies. Thanks @BenjaminVanRyseghem
  • Cleans up Numeral-js leftovers. Thanks @uniphil
  • Updates homepage url. Thanks @BenjaminVanRyseghem
  • Rebases on Numeraljs to keep git history. Thanks @uniphil @Graham42

1.0.4

Fork numeraljs v1.5.3, renaming everything to numbro


For changes before numbro forked numeral-js, see CHANGELOG-Numeraljs.md.