Skip to content

Instantly share code, notes, and snippets.

@CodeCurosity
Created December 20, 2019 15:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save CodeCurosity/971be8d49343111fec88e3f73d58360b to your computer and use it in GitHub Desktop.
Save CodeCurosity/971be8d49343111fec88e3f73d58360b to your computer and use it in GitHub Desktop.
<script>
// load a language
numeral.language('fr', {
delimiters: {
thousands: ' ',
decimal: ','
},
abbreviations: {
thousand: 'k',
million: 'm',
billion: 'b',
trillion: 't'
},
ordinal : function (number) {
return number === 1 ? 'er' : 'ème';
},
currency: {
symbol: '€'
}
});
// switch between languages
numeral.language('fr');
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment