1.0.5 • Published 5 years ago

camelcase-input v1.0.5

Weekly downloads
77
License
MIT
Repository
github
Last release
5 years ago

NPM Package To Convert Input Into lowerCamelcase Format

HitCount Generic badge GitHub license GitHub contributors GitHub issues GitHub issues-closed

NPM

Convert your input into lowerCamelcase format, this Node.js module allows you to convert string, array. object into lowerCamelcase.

Installation

Install with the node package manager npm:

  • Using npm
    $ npm install camelcase-input --save
  • Using yarn
    $ yarn add camelcase-input

How To Use?

Convert string Input

const camelcase = require('camelcase-input').camelcase
console.log(camelcase('Foo-Bar'))

/* OUTPUT */
fooBar

Convert object Input

const camelcase = require('camelcase-input').camelcase
console.log(camelcase({'foo-bar': true}))

/* OUTPUT */
{ fooBar: true }

Convert array of objects Input

const camelcase = require('camelcase-input').camelcase
console.log(camelcase([{'foo-bar': true}, {'is_that_you': true}]))

/* OUTPUT */
[ { fooBar: true }, { isThatYou: true } ]

Convert array of string Input

const camelcase = require('camelcase-input').camelcase
console.log(camelcase(['Foo-Bar', 'are-you-there']))

/* OUTPUT */
fooBar, areYouThere

Convert array of objects Input ({ deep: true })

const camelcase = require('camelcase-input').camelcase
console.log(camelcase([{'FOo-bar': [{'abc-df__r': true}, {'tghd_dfdf--ee': true}]}, {'bar-foo': { 'Test-te': {'opt-tdt': 'dfdfdf'} }}], { deep: true })))

/* OUTPUT */
[{ fooBar: [{ abcDfR: true }, { tghdDfdfEe: true }] },{ barFoo: { testTe: { optTdt: dfdfdf } } }]

Changelog

  • 1.0.0 Initial version
  • 1.0.1 email regex added (email is not converted)
  • 1.0.5 some issues resolved
1.0.5

5 years ago

1.0.4

5 years ago

0.0.8

6 years ago

1.0.3

6 years ago

0.0.7

6 years ago

1.0.2

6 years ago

0.0.6

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago