luxon icon indicating copy to clipboard operation
luxon copied to clipboard

Optimize Performance with Caching for Resolved Options and Parsed Locale Strings

Open nodify-at opened this issue 8 months ago • 12 comments

Changes

  • Caching: Implemented caching to avoid redundant computations of resolved options and locale parsing.
  • Efficient Checks: Introduced a final isEnglish variable to efficiently determine if the locale supports English.
  • Initialization: supportsFastNumbers is now immediately initialized to prevent unnecessary calls.

Performance Impact

Tests indicate up to a 10x speed improvement with these enhancements.

Issue Fixed

Fixes #1428

nodify-at avatar Jun 27 '24 13:06 nodify-at