Skip to main content

Units changelog

  • Changelog

@dynatrace-sdk/units

1.5.1 Released Mar 24, 2026​

Patch changes​

  • Update FormatCurrencyOptions documentation. APPDEV-16624
  • Fix format() returning an empty string for values in range (-0.5, 0.5) when using the smallest unit (e.g. millicore, byte) with maximumFractionDigits: 0. Such values now correctly render as < 1 unit or > -1 unit. (APPDEV-16777)

1.5.0 Released Jan 28, 2026​

Minor changes​

  • Migrated formatTimeValues, extractDisplayValueFromTimeValues, and formatTimeframe functions from the Strato Design System package to the SDK Unit package. These functions handle both absolute dates and relative expressions with full internationalization support. (PPFB-703)

1.4.2 Released Jan 23, 2026​

Patch changes​

  • Resolved an issue in formatTimeframeToParts util where inverted timeframes resulted in incorrect year values. (APPDEV-15821)

1.4.1 Released Dec 19, 2025​

Patch changes​

  • Widened react-intl peer dependency range to ^6.6.0 || ^7.0.0

1.4.0 Released Nov 25, 2025​

Minor changes​

  • Provide output unit when using getFormatter.(APPDEV-15191)
  • Set react-intl as peer dependency.

1.3.2 Released Oct 20, 2025​

Patch changes​

  • Remove redundant dependencies. (APPDEV-15017)

1.3.1 Released Oct 7, 2025​

Patch changes​

  • Now returns correct ISOString for all positive UTC offset timezones when using 'day' precision.

1.3.0 Released Sep 30, 2025​

Minor changes​

  • The formatTimeframeToParts function has been migrated from the Strato Design System package to the SDK Unit package. APPDEV-11727

1.2.0 Released Sep 26, 2025​

Minor changes​

  • Make expressions support offsets without a prefix (e.g., 1d@d instead of +1d@d). APPDEV-14636

Patch changes​

  • parseTime now returns a date string without Z (2025-08-14) if it has a 'day' precision to prevent faulty ISOStrings in Safari.
  • Formatter returns proper value, when no specific locale was provided and the runtime regional locale has changed. APPDEV-14771

1.1.8 Released Sep 17, 2025​

Patch changes​

  • Fix infinite value formatting. (APPDEV-14168)

1.1.7 Released Sep 10, 2025​

Patch changes​

  • Extend the react-intl version range to ^6.8.7 || ^7.0.0. APPDEV-14343

1.1.6 Released Sep 2, 2025​

Patch changes​

  • 215ba89b6ce: Fix parseTimeAsTimeValue to handle timezone information. (APPDEV-14483)

1.1.5 Released Aug 29, 2025​

Patch changes​

  • 940eaa1414d: Fix locale default value. (APPDEV-14091)

1.1.4 Released Jul 10, 2025​

Patch changes​

  • @w now automatically detects the user's region to determine the correct start day of the week in parseTimeAsTimeValue.

1.1.3 Released Jun 23, 2025​

Patch changes​

  • Improve variables section and rendering of object types. (APPDEV-13428)

1.1.2 Released Jun 10, 2025​

Patch changes​

  • Fix units abbreviation default. (APPDEV-13300)
  • fix: Improve documentation

1.1.1 Released May 28, 2025​

Patch changes​

  • Optimize performance by caching Intl API calls and streamlining locale handling. (APPDEV-12988)

1.1.0 Released May 13, 2025​

Minor changes​

  • The parseTimeAsTimeValue function now accepts a precision prop to remove parts of the ISOStrings. (APPDEV-10879)

1.0.3 Released Apr 23, 2025​

Patch changes​

  • Add '1' to the mapGrailUnit(). APPDEV-13008

1.0.2 Released Mar 3, 2025​

Patch changes​

  • The parseTimeAsTimeValue function now only sanitizes rounded timeframe expressions by removing the now prefix (e.g. ´now+1d@d´ to ´1d@d´). Relative timeframe values are no longer sanitized. (APPDEV-12365)

1.0.1 Released Feb 24, 2025​

Patch changes​

  • Fix a bug where the sdk threw a groupSymbols is undefined error when calling formatUnit(). (APPDEV-12046)

1.0.0 Released Feb 11, 2025​

Major changes​

  • Release of 1.0 version

Patch changes​

  • Add supported currencies to the types

0.19.0 Released Jan 27, 2025​

Minor changes​

  • Breaking Change: Update cascading lists and deprecate the liquid group

Patch changes​

  • Add timeframeTranslations. (APPDEV-10828)

0.18.11 Released Jan 21, 2025​

Patch changes​

  • ´parseTimeAsTimeValue´ and ´parseTime´ sanitize the expression to remove the ´now´ prefix (e.g. ´now+1h´ to ´1h´). (APPDEV-11731)

0.18.10 Released Dec 18, 2024​

Patch changes​

  • Invalid locales now fall back to en-US (APPDEV-11378)

0.18.9 Released Dec 11, 2024​

Patch changes​

  • ´parseTimeAsTimeValue´ now returns null when the ISOString is invalid.

0.18.8 Released Nov 29, 2024​

Patch changes​

  • Add bit_binary and byte_binary that will cascade with the binary prefixes. (APPDEV-10877)

0.18.7 Released Nov 27, 2024​

Patch changes​

  • Add mapGrailUnit function to convert grail units to a format @dynatrace-sdk/units is using

0.18.6 Released Nov 26, 2024​

Patch changes​

  • Bundle @date-fns/tz to make it available on the lambda layer. (APPDEV-11153)

0.18.5 Released Nov 18, 2024​

Patch changes​

  • Updated date-fns to 4.1.0 and replaced date-fns-tz with @date-fns/tz for better timezone handling.

0.18.4 Released Oct 30, 2024​

Patch changes​

  • Add abbreviate option to formatCurrency. APPDEV-10805

0.18.3 Released Oct 29, 2024​

Patch changes​

  • Enable TimeframeExpression additions

    • roundDownExpressions (eg. @d)
    • additional offsetUnits (eg. q) per default.

    The flag __STRATO__DO_NOT_USE__ENABLE_ROUND_DOWN_EXPRESSION does not have any effect anymore, so please remove the _RoundDownExpressionProvider if you were using it.

    (APPDEV-10733)

  • Add formatLong() function that can format long primitive data-types from Grail

0.18.2 Released Oct 22, 2024​

Patch changes​

  • Add formatCurrency function. APPDEV-10478
  • Add support for years in the offsetExpression when using the __STRATO__DO_NOT_USE__ENABLE_ROUND_DOWN_EXPRESSION feature flag.
  • Add support for @y @q @w @h @m @s in roundDownExpressions.

0.18.1 Released Oct 17, 2024​

Patch changes​

  • Fix near zero numbers being formatted as empty string

0.18.0 Released Oct 8, 2024​

Minor changes​

  • Add support for timezone Z formatting

0.17.0 Released Oct 1, 2024​

Minor changes​

  • Remove deprecated _migrateDeprecatedExpression function.

0.16.3 Released Sep 24, 2024​

Patch changes​

  • Fix cascading overflow error

0.16.2 Released Sep 23, 2024​

Patch changes​

  • parseTimeAsTimeValue() supports valid iso 8601 strings without hours, minutes, seconds or milliseconds.

0.16.1 Released Sep 5, 2024​

Patch changes​

  • Fix dependency issue

0.16.0 Released Sep 5, 2024​

Minor changes​

  • Remove usage of old dtsdk

0.15.0 Released Sep 2, 2024​

Minor changes​

  • Add significant digits option to formatter

0.14.3 Released Aug 28, 2024​

Patch changes​

  • Bundled the date-fns-tz dependency, so it is also available on the lambda layer.

0.14.2 Released Aug 23, 2024​

Patch changes​

  • The parseTimeAsTimeValue function now supports the roundDownExpression for days and months. Eg. -1d@d
  • The parseTime and parseTimeAsTimeValue now consider the user-settings' timezone when entering time in a certain format.

0.14.1 Released Aug 13, 2024​

Patch changes​

  • Temporary fix for invalid timezones with a pattern of UTC-*

0.14.0 Released Jul 25, 2024​

Minor changes​

  • Introduce new parseTime and deprecate old one.

Patch changes​

  • Improve locale detection accuracy.
  • Fix inconsistant formatting of large negative numbers.

0.13.2 Released Jun 24, 2024​

Patch changes​

  • formatDate() now respects user timezone.
  • Improve locale detection.
  • Fix bug in cascading.
  • Introduce Grail-compatible expression parser.
  • Add support for converting temperature units.
  • Change symbol of millicore to mcore.

0.13.1 Released Feb 26, 2024​

Patch changes​

  • Improve conversion accuracy.
  • Improve documentation.
  • Improve cascading precision.
  • Fix +/- Infinity abbreviation bug.

0.13.0 Released Feb 5, 2024​

Minor changes​

  • Fix bug resulting in type error when using a unit union as input type for the format functions.
  • BREAKING CHANGE: deprecating litre in favor of liter

0.12.0 Released Jan 19, 2024​

Minor changes​

  • BREAKING CHANGE: Changing the default settings to interpret bytes and bits in the decimal system.
  • Expose useGrouping option to format function

Patch changes​

  • Add support for non-convertible variants.
  • Fix bug where Bel and ratio are treated as variants.
  • Fix a bug where cascading inside the format function caused problems with rounded values

0.11.1 Released Dec 4, 2023​

Patch changes​

  • Bundle date-fns

0.11.0 Released Nov 17, 2023​

Minor changes​

  • Add parseTime to the units package.

Patch changes​

  • Make undefined a valid input unit.
  • Make number abbreviation respect locale.
  • Make core unit cascade.

0.10.1 Released Oct 9, 2023​

Patch changes​

  • Corrected the documentation of the cascade functionality.

0.10.0 Released Oct 4, 2023​

Minor changes​

    • Marks units.percentage.promile and units.time_squared.second_squared as depricated

    • Added new units units.percentage.per_mille and units.time_squared.square_second

    • Correct other spelling mistakes

    BREAKING CHANGE:

    • Renamed ConvertableUnit to ConvertibleUnit
    • Renamed FormatableUnit to FormattableUnit
  • Implement getFormatting function to retrieve decomposed formatting parts. Use case: Display the symbol somewhere else not just next to the value.

0.9.0 Released Sep 19, 2023​

Minor changes​

  • Expose the minimumFractionDigits option.
  • Add missing units and correct formatting.
  • BREAKING CHANGE
    • Pixel does not have SI prefixes, but only px, MP and GP.
  • Fix problem with locales that include lvariant in the private-use extension
  • Simplify and improve types
  • Add support for compound variants

Patch changes​

  • Corrected the conversion factor of ounce.

0.8.3 Released Jul 10, 2023​

Patch changes​

  • Correct symbols used for a thousand and a billion when abbreviating the numbers.

0.8.2 Released Jun 27, 2023​

Patch changes​

  • Update documentation

0.8.1 Released Jun 6, 2023​

Patch changes​

  • Use seaotter links.

0.8.0 Released Apr 27, 2023​

Minor changes​

  • The precision was removed from the abbreviateNumber() options, and instead, minimumFractionDigits and maximumFractionDigits were added to match the Intl API.

Patch changes​

  • Correcting the import in a docs example.

0.7.1 Released Apr 5, 2023​

Patch changes​

  • Add ConvertibleUnit, ConvertiblePack, FormattableUnit to documentation.
  • Add description, homepage and keywords to package.json

0.7.0 Released Apr 3, 2023​

Minor changes​

  • Cascade time up to weeks.

0.6.0 Released Mar 20, 2023​

Minor changes​

  • Some units have been removed from the cascade list. Affected unit groups are length and mass.

Patch changes​

  • Export CUnit and Unit types

0.5.2 Released Mar 14, 2023​

Patch changes​

  • Fixes the calculation of a month.
  • Fixes a bug where negative numbers have been transformed to positive numbers.
  • Improve documentation

0.5.1 Released Feb 28, 2023​

Patch changes​

  • Set missing package license.

0.5.0 Released Feb 23, 2023​

Minor changes​

  • Adds documentation to the units package.

Patch changes​

  • Add support for negative numbers in abbreviate and cascade.

0.4.0 Released Feb 8, 2023​

Minor changes​

  • Adds abbreviate and auto cascade feature to the format api.

0.3.0 Released Jan 19, 2023​

Minor changes​

  • Renamed package from util-formatters to units. Decimals naming has also been changed to fraction digits.

0.3.0 Released Jan 19, 2023​

Minor changes​

  • Adds convert functionality.
  • Give the user the option to override the locale.
  • Add cascade feature for all SI units.

Patch changes​

  • Add missing SI factors and remove unneeded units.

0.2.0​

Minor changes​

  • Allow to overwrite locale for formatDate and use sdkWeb as a default source for locales if available.
  • Add abbreviate number functionality

0.1.0​

Patch changes​

  • Initial release of @dynatrace-sdk/util-formatters.
Still have questions?
Find answers in the Dynatrace Community