Convert camelCase to kebab-case!

String
Result

Convert camelCase to kebab-case!

Is the variable naming in the code you copied from somewhere else different from your code? Don't worry! It converts variables to your desired naming convention!

Example

<camelCase>
const myVar = "hello world!";
<kebab-case>
const my-var = "hello world!";

Description

camelCase

camelCase is a method of writing names where the first letter of each word is capitalized, except for the first word, making it look like a camel's hump, hence the name camelCase.

kebab-case

kebab-case writes words in lowercase and separates them with hyphens (-). This notation is commonly used in web development and for file names.

snake_case

snake_case involves writing each word in lowercase and separating words with underscores (_). This notation is commonly used for variable names and function names.

SCREAMING_SNAKE_CASE

SCREAMING_SNAKE_CASE writes all words in uppercase and separates words with underscores (_). This notation is primarily used for defining constants.

PascalCase

PascalCase capitalizes the first letter of each word and does not use spaces or separators between words. This notation is mainly used for identifiers such as class names.