UNPKG

@polkadot/util

Version:
16 lines (15 loc) 453 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getSeparator = void 0; /** * Get the decimal and thousand separator of a locale * @param locale * @returns {decimal: string, thousand: string} */ function getSeparator(locale) { return { decimal: (0.1).toLocaleString(locale).substring(1, 2), thousand: (1000).toLocaleString(locale).substring(1, 2) }; } exports.getSeparator = getSeparator;