Have ideas to improve npm?Join in the discussion! »

snake-case
TypeScript icon, indicating that this package has built-in type declarations

3.0.4 • Public • Published

Snake Case

NPM version NPM downloads Bundle size

Transform into a lower case string with underscores between words.

Installation

npm install snake-case --save

Usage

import { snakeCase } from "snake-case";

snakeCase("string"); //=> "string"
snakeCase("dot.case"); //=> "dot_case"
snakeCase("PascalCase"); //=> "pascal_case"
snakeCase("version 1.2.10"); //=> "version_1_2_10"

The function also accepts options.

License

MIT

Install

npm i snake-case

DownloadsWeekly Downloads

2,361,366

Version

3.0.4

License

MIT

Unpacked Size

10.4 kB

Total Files

15

Last publish

Collaborators

  • avatar