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

0.7.0 • Public • Published

luthier

noun (lu·thi·er)

one who makes stringed musical instruments (such as violins or guitars)

luthier handles all of your string needs. 🎸

License Node Version Test Status Code Coverage

Installation

npm install luthier --save
# or
yarn add luthier

Usage

import { luthier } from 'luthier';

Functions

camelCase

luthier.camelCase('your string');
// 'yourString'

constantCase

luthier.constantCase('your string');
// 'YOUR_STRING'

containsLetters

luthier.containsLetters('your string');
// true

containsLowerCasedLetters

luthier.containsLowerCasedLetters('your string');
// true

containsNumbers

luthier.containsNumbers('your string');
// false

containsOnlyLetters

luthier.containsLetters('your string');
// false

containsOnlyLowerCasedLetters

luthier.containsOnlyLowerCasedLetters('your string');
// false

containsOnlyNumbers

luthier.containsOnlyNumbers('your string');
// false

containsOnlySpecialCharacters

luthier.containsOnlySpecialCharacters('your string');
// false

containsOnlyUpperCasedLetters

luthier.containsOnlyUpperCasedLetters('your string');
// false

containsSpecialCharacters

luthier.containsSpecialCharacters('your string');
// true

containsUpperCasedLetters

luthier.containsUpperCasedLetters('your string');
// false

countLines

luthier.countLines('your\nstring');
// 2

countWords

luthier.countWords('your string');
// 2

customCase

luthier.customCase('+', 'your string');
// 'your+string'

dotCase

luthier.dotCase('your string');
// 'your.string'

flip

luthier.flip('your string');
// 'ɓuᴉɹʇs ɹnoʎ'

initials

luthier.initials('your string');
// 'YG'

isCamelCased

luthier.isCamelCased('your string');
// false

isCapitalized

luthier.isCapitalized('your string');
// false

isConstantCased

luthier.isConstantCased('your string');
// false

isDotCased

luthier.isDotCased('your string');
// false

isKebabCased

luthier.isKebabCased('your string');
// false

isLowerCased

luthier.isKebabCased('your string');
// true

isPascalCased

luthier.isPascalCased('your string');
// false

isSnakeCased

luthier.isSnakeCased('your string');
// false

isStartCased

luthier.isStartCased('your string');
// false

isStudlyCapped

luthier.isStudlyCapped('your string');
// false

isUpperCased

luthier.isUpperCased('your string');
// false

kebabCase

luthier.kebabCase('your string');
// 'your-string'

lowerCaseFirst

luthier.lowerCaseFirst('Your string');
// 'your string'

lowerCaseWords

luthier.lowerCaseWords('Your String');
// 'your string'

numeronym

luthier.numeronym('your string');
// 'y8g'

pascalCase

luthier.pascalCase('your string');
// 'YourString'

random

luthier.random(10);
// 'psifnwkflr'

reverse

luthier.reverse('your string');
// 'gnirts ruoy'

rot13

luthier.rot13('your string');
// 'lbhe fgevat'

shuffle

luthier.shuffle('your string');
// 'nru grsioty'

snakeCase

luthier.snakeCase('your string');
// 'your_string'

startCase

luthier.startCase('your string');
// 'Your String'

stripTags

luthier.stripTags('<em>your string</em>');
// 'your string'

studlyCaps

luthier.studlyCaps('your string');
// 'YoUr StRiNg'

upperCaseFirst

luthier.upperCaseFirst('your string');
// 'Your string'

upperCaseWords

luthier.upperCaseWords('your string');
// 'Your String'

Unlike startCase, the upperCaseWords method does not apply String.prototype.toLowerCase() first.

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i luthier

Weekly Downloads

0

Version

0.7.0

License

MIT

Unpacked Size

53.2 kB

Total Files

163

Last publish

Collaborators

  • joshtronic