docs: function formatCurrency(value, locale, currency, currencyCode, digitsInfo) {
      var format = getLocaleNumberFormat(locale, NumberFormatStyle.Currency);
      var pattern = parseNumberFormat(format, getLocaleNumberSymbol(locale, NumberSymbol.MinusSign));
      pattern.minFrac = getNumberOfCurrencyDigits(currencyCode);
      pattern.maxFrac = pattern.minFrac;
      var res = formatNumberToLocaleString(value, pattern, locale, NumberSymbol.CurrencyGroup, NumberSymbol.CurrencyDecimal, digitsInfo);
      return res
          .replace(CURRENCY_CHAR, currency)
          // if we have 2 time the currency character, the second one is ignored
          .replace(CURRENCY_CHAR, '');
  }