Converts strings (or arrays of strings) from dash, dot, underscore, or space separated formats into camelCase, with an option to output PascalCase. It also handles Unicode correctly, making it useful when normalizing user input or identifiers into JavaScript-style casing.
Project status
- The source appears actively maintained, with the most recent upstream push and update being v9.0.0 on 2025-11-10.
- The update cadence is somewhat irregular, with prior updates at v8.0.0 (2023-08-09) and v7.0.1 (2022-12-13), and a longer gap before v9.0.0 (about 2 years after v8).
AI summary generated Today
Recent updates
v9.0.0
6 months agov9.0.0 raises the minimum supported Node.js version to 20 and adds a new `capitalizeAfterNumber` option. The implementation was refactored around case preservation and word-boundary detection, with a notable behavioral change in how leading underscores are handled.
BreakingFeaturesv8.0.0
8/9/2023v8.0.0 raises the minimum supported Node.js version to 16 and includes a fix for incorrect camelization behavior. The code changes also show an implementation update to the internal string processing logic (not just a documentation or test tweak), with additional test coverage for digit and underscore/dash boundaries.
Breakingv7.0.1
12/13/2022v7.0.1 makes a targeted fix for the `preserveConsecutiveUppercase` option. The code adjusts how camelCase is preserved across consecutive uppercase sequences, and the tests reflect updated expected casing behavior for inputs like `IDs`.
v7.0.0
6/6/2022v7.0.0 makes camelcase a pure ESM package and raises the minimum supported Node.js version to 14. It also changes behavior so that providing a separator character as the entire input returns an empty string.
Breakingv6.3.0
1/1/2022v6.3.0 adds support for disabling the platform locale by allowing `locale: false`. The implementation introduces locale-aware `toLowerCase` and `toUpperCase` helper functions and routes case conversions through them, including new tests and documentation.
Featuresv6.2.1
11/15/2021v6.2.1 is presented as an internal readability change, but the diff shows a substantive refactor of the camelCase implementation around Unicode regex handling. It also updates CI configuration, README wording/examples, and test coverage.
v6.2.0
10/28/2020Release v6.2.0 adds a new boolean option, preserveConsecutiveUppercase, to control how consecutive uppercase sequences are handled during camelCase/PascalCase conversion. The implementation also refactors the casing and post-processing pipeline to route through the new option.
Featuresv6.1.0
10/10/2020v6.1.0 primarily adds a new `locale` option to control locale-specific upper/lowercasing during camelCase/PascalCase conversion. The implementation threads the locale through all case conversions (including special handling for preserving existing casing), and updates TypeScript typings and tests accordingly.
Featuresv6.0.0
4/7/2020v6.0.0 raises the minimum supported Node.js version to 10 and updates camelcase conversion logic to better handle Unicode casing. The code also includes several additional behavioral and TypeScript typing changes beyond what the release notes explicitly describe.
BreakingFeaturesv5.3.1
4/3/2019v5.3.1 contains a targeted change to camelcase conversion logic intended to fix a regression in how numbers are handled. The release notes only state that numbers treatment was fixed, but the code change shows a concrete behavior update for letters following digit sequences.