UNPKG

453 BJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3exports.getSeparator = void 0;
4/**
5 * Get the decimal and thousand separator of a locale
6 * @param locale
7 * @returns {decimal: string, thousand: string}
8 */
9function getSeparator(locale) {
10 return {
11 decimal: (0.1).toLocaleString(locale).substring(1, 2),
12 thousand: (1000).toLocaleString(locale).substring(1, 2)
13 };
14}
15exports.getSeparator = getSeparator;