This package has been deprecated

Author message:

Use `change-case`

constant-case
DefinitelyTyped icon, indicating that this package has TypeScript declarations provided by the separate @types/constant-case package

4.0.0 • Public • Published

Constant Case

Transform into upper case string with an underscore between words.

Installation

npm install constant-case --save

Usage

import { constantCase } from "constant-case";

constantCase("string"); //=> "STRING"
constantCase("dot.case"); //=> "DOT_CASE"
constantCase("PascalCase"); //=> "PASCAL_CASE"
constantCase("version 1.2.10"); //=> "VERSION_1_2_10"

The function also accepts options.

License

MIT

Package Sidebar

Install

npm i constant-case

Weekly Downloads

5,216,145

Version

4.0.0

License

MIT

Unpacked Size

2.6 kB

Total Files

5

Last publish

Collaborators

  • blakeembrey