1. camel-case
Transform into a string with the separator denoted by the next word capitalized
camel-case
Package: camel-case
Created by: blakeembrey
Last modified: Sat, 30 Sep 2023 01:46:30 GMT
Version: 5.0.0
License: MIT
Downloads: 73,166,485
Repository: https://github.com/blakeembrey/change-case

Install

npm install camel-case
yarn add camel-case

Camel Case

Transform into a string with the separator denoted by the next word capitalized.

Installation

npm install camel-case --save

Usage

 import { camelCase } from "camel-case";

camelCase("string"); //=> "string"
camelCase("dot.case"); //=> "dotCase"
camelCase("PascalCase"); //=> "pascalCase"
camelCase("version 1.2.10"); //=> "version_1_2_10"

The function also accepts options.

Merge Numbers

If you'd like to remove the behavior prefixing _ before numbers, you can use camelCaseTransformMerge:

 import { camelCaseTransformMerge } from "camel-case";

camelCase("version 12", { transform: camelCaseTransformMerge }); //=> "version12"

License

MIT

Dependencies

RELATED POST

10 Must-Know Windows Shortcuts That Will Save You Time

10 Must-Know Windows Shortcuts That Will Save You Time

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Arrays vs Linked Lists: Which is Better for Memory Management in Data Structures?

Navigating AWS Networking: Essential Hacks for Smooth Operation

Navigating AWS Networking: Essential Hacks for Smooth Operation

Achieving Stunning Visuals with Unity's Global Illumination

Achieving Stunning Visuals with Unity's Global Illumination

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code

Nim's Hidden Gems: Lesser-known Features for Writing Efficient Code